|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.tree.DefaultMutableTreeNode
jsynoptic.plugins.java3d.tree.AbstractNode
jsynoptic.plugins.java3d.tree.SceneGraphNode
public class SceneGraphNode
A Node to hold a Scene Graph Object
Nested Class Summary | |
---|---|
static class |
SceneGraphNode.CopyAction
|
static class |
SceneGraphNode.CutAction
|
static class |
SceneGraphNode.PasteAction
|
static class |
SceneGraphNode.PropertiesAction
|
static class |
SceneGraphNode.RemoveAction
|
Field Summary | |
---|---|
static MenuResourceBundle |
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 | |
---|---|
SceneGraphNode(Tree tree,
java.lang.Object graphObject,
boolean getChildren)
|
Method Summary | |
---|---|
static void |
addActions(java.lang.String className,
java.lang.Object... actions)
|
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)
This default implementation simply checks if a tree node class exists as a children of the current node This is used a default rule used to check the compatibility of the scene graph object with the current object |
boolean |
canPaste()
|
SceneGraphNode |
cloneNode(boolean deepClone,
AbstractNode parent)
A generic tree node clone method A new tree node is created with inside a clone of the original scene graph One can override if needed |
void |
copy()
|
void |
cut()
|
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 |
java.lang.String |
getName()
|
protected void |
getSceneGraphChildren(java.util.ArrayList<java.lang.Object> list)
Get the list of children of this scene graph object |
void |
paste()
|
void |
remove()
|
void |
removeSceneGraphObject(SceneGraphObject obj,
SceneGraphObject oldObj)
Remove one scene graph object |
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 |
Field Detail |
---|
public static MenuResourceBundle sharedResources
Constructor Detail |
---|
public SceneGraphNode(Tree tree, java.lang.Object graphObject, boolean getChildren)
Method Detail |
---|
public static void addActions(java.lang.String className, java.lang.Object... actions)
public java.lang.String getName()
getName
in class AbstractNode
protected java.lang.Class<?> getChildrenNodeClass(java.lang.Object sceneGraphObject)
AbstractNode
getChildrenNodeClass
in class AbstractNode
sceneGraphObject
- a child object of this Node scene graph object
createNode
protected void getSceneGraphChildren(java.util.ArrayList<java.lang.Object> list)
AbstractNode
getSceneGraphChildren
in class AbstractNode
list
- the list to fill with the scene graph childrenpublic boolean canAddSceneGraphObject(SceneGraphObject obj)
canAddSceneGraphObject
in interface AddRemoveSceneGraphObject
obj
- the object to add
public SceneGraphObject addSceneGraphObject(SceneGraphObject obj)
AddRemoveSceneGraphObject
addSceneGraphObject
in interface AddRemoveSceneGraphObject
obj
- the object to add
public void removeSceneGraphObject(SceneGraphObject obj, SceneGraphObject oldObj)
AddRemoveSceneGraphObject
removeSceneGraphObject
in interface AddRemoveSceneGraphObject
obj
- the object to removeoldObj
- the optional object to be used in place ofpublic void paste()
public boolean canPaste()
public void copy()
public void cut()
public void remove()
public SceneGraphNode cloneNode(boolean deepClone, AbstractNode parent)
forceDuplicate
- if true force duplication of nodes and sub graph nodesparent
- used to create a new tree node according to the cloned
scene graph object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |