jsynoptic.plugins.java3d.edit
Interface AddRemoveSceneGraphObject

All Known Implementing Classes:
AnimatorNode, AppearanceNode, BranchGroupNode, GroupNode, PrimitiveNode, SceneGraphNode, ShapeNode, TransformAnimatorNode

public interface AddRemoveSceneGraphObject

Defines the operation to be implemented by an object able to remove or add a scene graph object to the scene graph at the place this object defines For instance a tree used to display the scene graph is composed of nodes. Each node refers to one scene graph object. By implementing these operations each tree node can provide a polymorphic add/remove operation on all the elements part of the scene graph.


Method Summary
 SceneGraphObject addSceneGraphObject(SceneGraphObject obj)
          Add one scene graph object According to the target, this new object can replace the previous object or be added to a list
 boolean canAddSceneGraphObject(SceneGraphObject obj)
          Checks if a scene graph object can be added
 void removeSceneGraphObject(SceneGraphObject obj, SceneGraphObject oldObj)
          Remove one scene graph object
 

Method Detail

canAddSceneGraphObject

boolean canAddSceneGraphObject(SceneGraphObject obj)
Checks if a scene graph object can be added

Parameters:
obj - the object to add
Returns:
true if it can be added

addSceneGraphObject

SceneGraphObject addSceneGraphObject(SceneGraphObject obj)
Add one scene graph object According to the target, this new object can replace the previous object or be added to a list

Parameters:
obj - the object to add
Returns:
the replace object or null if simply added

removeSceneGraphObject

void removeSceneGraphObject(SceneGraphObject obj,
                            SceneGraphObject oldObj)
Remove one scene graph object

Parameters:
obj - the object to remove
oldObj - the optional object to be used in place of