|
Xj3D VRML/X3D Code API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
An abstract representation of the root node of a world.
We need a root node representation to act as a standard place to collate all the nodes of a world. While the XML encoding provides a single root node in the X3D element, the UTF8 encoding does not. This class acts as that sort of collector. For the XML code or the UTF8 code, we would expect more concrete implemetations of this interface to be derived.
While this could be a VRMLGroupingNodeType we really don't want
to extend that interface. It implies that this node could then be inserted
anywhere into the scenegraph. That we want to prevent. Instead, we just copy
all the methods here. We also copy the bounded node methods because these
might be useful. We do not require implementations to figure out the bounds,
but if they do then it would be nice to grab that information.
| Method Summary | |
void |
addChild(VRMLNodeType newChild)
Append a new child node to the existing collection. |
float[] |
getBboxCenter()
Accessor method to get current value of field bboxCenter default value is 0 0 0. |
float[] |
getBboxSize()
Accessor method to get current value of field bboxSize default value is -1 -1 -1. |
VRMLNodeType[] |
getChildren()
Get the children, provides a live reference not a copy |
int |
getChildrenSize()
Returns the number of children |
void |
removeChild(VRMLNodeType removeChild)
Remove an existing child node from the collection. |
void |
setBboxCenter(float[] newBboxCenter)
Accessor method to set a new value for field attribute bboxCenter |
void |
setBboxSize(float[] newBboxSize)
Accessor method to set a new value for field attribute bboxSize |
void |
setChildren(VRMLNodeType newChild)
Accessor method to set the children field Creates an array containing only newChild If passed null this method will act like removeChildren |
void |
setChildren(VRMLNodeType[] newChildren)
Accesor method to set the children field If passed null this method will act like removeChildren |
void |
setContainedScene(BasicScene scene)
Set the scene that is contained by this world, which happens to be an execution space. |
| Methods inherited from interface org.web3d.vrml.nodes.VRMLNodeType |
addNodeListener, getFieldValue, getMetadataObject, getRefCount, hasFieldChanged, isSetupFinished, notifyExternProtoLoaded, removeNodeListener, sendRoute, setDEF, setFrameStateManager, setMetadataObject, setupFinished, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, updateRefCount |
| Methods inherited from interface org.web3d.vrml.lang.VRMLNode |
getFieldDeclaration, getFieldIndex, getNodeFieldIndices, getNumFields, getPrimaryType, getSecondaryType, getUserData, getVRMLNodeName, isDEF, setErrorReporter, setUserData, setVersion |
| Methods inherited from interface org.web3d.vrml.nodes.FrameStateListener |
allEventsComplete |
| Methods inherited from interface org.web3d.vrml.lang.VRMLExecutionSpace |
getContainedScene |
| Method Detail |
public void setContainedScene(BasicScene scene)
scene - The scene to usepublic void setBboxCenter(float[] newBboxCenter)
newBboxCenter - The new center of the bounding boxpublic float[] getBboxCenter()
0 0 0.
public void setBboxSize(float[] newBboxSize)
newBboxSize - The new size for the bounding boxpublic float[] getBboxSize()
-1 -1 -1.
public VRMLNodeType[] getChildren()
public void setChildren(VRMLNodeType[] newChildren)
newChildren - Array of new childrenpublic void setChildren(VRMLNodeType newChild)
newChild - The new childpublic int getChildrenSize()
public void addChild(VRMLNodeType newChild)
newChild - The new childpublic void removeChild(VRMLNodeType removeChild)
removeChild - The child to remove
|
Xj3D VRML/X3D Code API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||