jsynoptic.plugins.java3d.tree
Class GroupNode

java.lang.Object
  extended by javax.swing.tree.DefaultMutableTreeNode
      extended by jsynoptic.plugins.java3d.tree.AbstractNode
          extended by jsynoptic.plugins.java3d.tree.SceneGraphNode
              extended by jsynoptic.plugins.java3d.tree.GroupNode
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, javax.swing.tree.MutableTreeNode, javax.swing.tree.TreeNode, AddRemoveSceneGraphObject
Direct Known Subclasses:
BranchGroupNode, PrimitiveNode

public class GroupNode
extends SceneGraphNode

A Node to hold a Group Node

See Also:
Serialized Form

Nested Class Summary
static class GroupNode.LoaderHandler
           
 
Nested classes/interfaces inherited from class jsynoptic.plugins.java3d.tree.SceneGraphNode
SceneGraphNode.CopyAction, SceneGraphNode.CutAction, SceneGraphNode.PasteAction, SceneGraphNode.PropertiesAction, SceneGraphNode.RemoveAction
 
Field Summary
 
Fields inherited from class jsynoptic.plugins.java3d.tree.SceneGraphNode
sharedResources
 
Fields inherited from class jsynoptic.plugins.java3d.tree.AbstractNode
_name
 
Fields inherited from class javax.swing.tree.DefaultMutableTreeNode
allowsChildren, children, EMPTY_ENUMERATION, parent, userObject
 
Constructor Summary
GroupNode(Tree tree, java.lang.Object graphObject, boolean getChildren)
           
 
Method Summary
 void addChild(Node n)
           
 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
protected  java.lang.Class<?> getChildrenNodeClass(java.lang.Object sceneGraphObject)
          According to a child scene graph object, returns the class of the Node to hold it in the Tree
protected  void getSceneGraphChildren(java.util.ArrayList<java.lang.Object> list)
          Get the list of children of this scene graph object
 void removeChild(Node n)
           
 void removeSceneGraphObject(SceneGraphObject obj, SceneGraphObject oldObj)
          Remove one scene graph object
 
Methods inherited from class jsynoptic.plugins.java3d.tree.SceneGraphNode
addActions, canAddSceneGraphObject, canPaste, cloneNode, copy, cut, getName, paste, remove
 
Methods inherited from class jsynoptic.plugins.java3d.tree.AbstractNode
addResource, addResources, createNode, getAllowsChildren, getChildCount, getDescription, getGraphObject, getIcon, getOwner, getTree, refresh
 
Methods inherited from class javax.swing.tree.DefaultMutableTreeNode
add, breadthFirstEnumeration, children, clone, depthFirstEnumeration, getChildAfter, getChildAt, getChildBefore, getDepth, getFirstChild, getFirstLeaf, getIndex, getLastChild, getLastLeaf, getLeafCount, getLevel, getNextLeaf, getNextNode, getNextSibling, getParent, getPath, getPathToRoot, getPreviousLeaf, getPreviousNode, getPreviousSibling, getRoot, getSharedAncestor, getSiblingCount, getUserObject, getUserObjectPath, insert, isLeaf, isNodeAncestor, isNodeChild, isNodeDescendant, isNodeRelated, isNodeSibling, isRoot, pathFromAncestorEnumeration, postorderEnumeration, preorderEnumeration, remove, remove, removeAllChildren, removeFromParent, setAllowsChildren, setParent, setUserObject, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GroupNode

public GroupNode(Tree tree,
                 java.lang.Object graphObject,
                 boolean getChildren)
Method Detail

getChildrenNodeClass

protected java.lang.Class<?> getChildrenNodeClass(java.lang.Object sceneGraphObject)
Description copied from class: AbstractNode
According to a child scene graph object, returns the class of the Node to hold it in the Tree

Overrides:
getChildrenNodeClass in class SceneGraphNode
Parameters:
sceneGraphObject - a child object of this Node scene graph object
Returns:
the class to use to create the Node
See Also:
createNode

getSceneGraphChildren

protected void getSceneGraphChildren(java.util.ArrayList<java.lang.Object> list)
Description copied from class: AbstractNode
Get the list of children of this scene graph object

Overrides:
getSceneGraphChildren in class SceneGraphNode
Parameters:
list - the list to fill with the scene graph children

addSceneGraphObject

public SceneGraphObject addSceneGraphObject(SceneGraphObject obj)
Description copied from interface: AddRemoveSceneGraphObject
Add one scene graph object According to the target, this new object can replace the previous object or be added to a list

Specified by:
addSceneGraphObject in interface AddRemoveSceneGraphObject
Overrides:
addSceneGraphObject in class SceneGraphNode
Parameters:
obj - the object to add
Returns:
the replace object or null if simply added

removeSceneGraphObject

public void removeSceneGraphObject(SceneGraphObject obj,
                                   SceneGraphObject oldObj)
Description copied from interface: AddRemoveSceneGraphObject
Remove one scene graph object

Specified by:
removeSceneGraphObject in interface AddRemoveSceneGraphObject
Overrides:
removeSceneGraphObject in class SceneGraphNode
Parameters:
obj - the object to remove
oldObj - the optional object to be used in place of

addChild

public void addChild(Node n)

removeChild

public void removeChild(Node n)