swingwtx.swing.tree
Class DefaultMutableTreeNode
java.lang.Object
swingwtx.swing.tree.DefaultMutableTreeNode
- All Implemented Interfaces:
- MutableTreeNode, TreeNode
- public class DefaultMutableTreeNode
- extends java.lang.Object
- implements MutableTreeNode
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
peer
public org.eclipse.swt.widgets.TreeItem peer
- The SWT TreeItem peer
EMPTY_ENUMERATION
public static final java.util.Enumeration EMPTY_ENUMERATION
- An empty enumeration
parent
protected MutableTreeNode parent
allowsChildren
protected boolean allowsChildren
children
protected java.util.Vector children
userObject
protected java.lang.Object userObject
DefaultMutableTreeNode
public DefaultMutableTreeNode()
DefaultMutableTreeNode
public DefaultMutableTreeNode(java.lang.Object userObject)
DefaultMutableTreeNode
public DefaultMutableTreeNode(java.lang.Object userObject,
boolean allowsChildren)
insert
public void insert(MutableTreeNode newChild,
int childIndex)
- Specified by:
insert in interface MutableTreeNode
remove
public void remove(int childIndex)
- Specified by:
remove in interface MutableTreeNode
add
public void add(MutableTreeNode newChild)
setParent
public void setParent(MutableTreeNode newParent)
- Specified by:
setParent in interface MutableTreeNode
getParent
public TreeNode getParent()
- Specified by:
getParent in interface TreeNode
removeFromParent
public void removeFromParent()
- Specified by:
removeFromParent in interface MutableTreeNode
getChildAt
public TreeNode getChildAt(int index)
- Specified by:
getChildAt in interface TreeNode
getChildCount
public int getChildCount()
- Specified by:
getChildCount in interface TreeNode
getIndex
public int getIndex(TreeNode aChild)
- Specified by:
getIndex in interface TreeNode
children
public java.util.Enumeration children()
- Specified by:
children in interface TreeNode
getAllowsChildren
public boolean getAllowsChildren()
- Specified by:
getAllowsChildren in interface TreeNode
setAllowsChildren
public void setAllowsChildren(boolean allows)
getUserObject
public java.lang.Object getUserObject()
setUserObject
public void setUserObject(java.lang.Object userObject)
- Specified by:
setUserObject in interface MutableTreeNode
remove
public void remove(MutableTreeNode aChild)
- Specified by:
remove in interface MutableTreeNode
removeAllChildren
public void removeAllChildren()
isLeaf
public boolean isLeaf()
- Specified by:
isLeaf in interface TreeNode
getPath
public TreeNode[] getPath()
isNodeAncestor
public boolean isNodeAncestor(TreeNode anotherNode)
isNodeDescendant
public boolean isNodeDescendant(DefaultMutableTreeNode anotherNode)
getRoot
public TreeNode getRoot()
isRoot
public boolean isRoot()
toString
public java.lang.String toString()