|
Xj3D 2.0 VRML/X3D Code API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface BasicScene
Abstract representation of a contained scene graph.
The scene returns lists of nodes of the given type. This list contains all of the nodes of that type in the order that they are declared in the incoming stream. As the scene changes due to scripting and external interactions, it will add new instances of these nodes to the end of the list. If there is none of the given node types, the methods shall return empty lists.
| Method Summary | |
|---|---|
void |
addNode(VRMLNode node)
Add a node to this scene. |
void |
addTemplate(VRMLNodeTemplate template)
Add a new template to this scene. |
java.util.ArrayList |
getByPrimaryType(int type)
Get the list of nodes of the given primary type declared in this scene. |
java.util.ArrayList |
getBySecondaryType(int type)
Get the list of nodes of the given secondary type declared in this scene. |
java.util.Map |
getDEFNodes()
Get a list of the nodes that have been named with DEF in this scene. |
java.util.Map |
getImports()
Get the IMPORT declaration information from this scene. |
int |
getLayerId()
Get the layer ID of this scene. |
java.lang.String |
getLoadedURI()
Get the URI of the world that this scene represents. |
SceneMetaData |
getMetaData()
Get the meta data associated with this scene. |
VRMLNodeFactory |
getNodeFactory()
Get the node factory that represents the setup of this scene. |
VRMLNodeTemplate |
getNodeTemplate(java.lang.String name)
Get the proto defined by the name. |
java.util.ArrayList |
getNodeTemplates()
Get the list of top-level node templates declared in this scene. |
VRMLNode |
getRootNode()
Get the node that forms the root of this proto body. |
java.util.ArrayList |
getRoutes()
Get the list of ROUTEs declared in this scene. |
int |
getSpecificationMajorVersion()
Get the specification major version that this scene belongs to. |
int |
getSpecificationMinorVersion()
Get the specification minor version that this scene belongs to. |
java.lang.String |
getWorldRootURL()
Get the Root URL of the world that this scene represents. |
void |
removeNode(VRMLNode node)
Remove a node from this scene. |
void |
removeTemplate(VRMLNodeTemplate template)
Remove a template from this scene. |
void |
setLayerId(int id)
Set the layer ID of this scene. |
void |
setNodeFactory(VRMLNodeFactory fac)
Set the node factory instance to be used with this scene. |
| Method Detail |
|---|
int getLayerId()
void setLayerId(int id)
id - A non-negative layer identifierSceneMetaData getMetaData()
VRMLNode getRootNode()
java.lang.String getWorldRootURL()
java.lang.String getLoadedURI()
VRMLNodeFactory getNodeFactory()
void setNodeFactory(VRMLNodeFactory fac)
throws java.lang.IllegalArgumentException,
java.lang.IllegalStateException
fac - The factory instance to use
java.lang.IllegalArgumentException - The factory instance provided was null
java.lang.IllegalStateException - A factory has already been setint getSpecificationMajorVersion()
int getSpecificationMinorVersion()
void addNode(VRMLNode node)
node - The node to addvoid removeNode(VRMLNode node)
node - The node to addvoid addTemplate(VRMLNodeTemplate template)
template - The new template instance to usevoid removeTemplate(VRMLNodeTemplate template)
template - The template instance to removejava.util.ArrayList getRoutes()
java.util.ArrayList getNodeTemplates()
java.util.ArrayList getByPrimaryType(int type)
java.util.ArrayList getBySecondaryType(int type)
VRMLNodeTemplate getNodeTemplate(java.lang.String name)
name - The name of the proto to fetch.
java.util.Map getDEFNodes()
VRMLNodeType instances. If there are no nodes marked with
DEF then the map will be empty.
java.util.Map getImports()
|
Xj3D 2.0 VRML/X3D Code API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||