public class GenericTreeNode
extends java.lang.Object
Constructor and Description |
---|
GenericTreeNode() |
Modifier and Type | Method and Description |
---|---|
void |
add(GenericTreeNode child) |
void |
addAttribute(java.lang.Object attribute) |
<T> T |
getAttribute(java.lang.Class<T> clazz) |
int |
getDepth() |
GenericTreeNode |
getChildAt(int index) |
int |
getChildCount() |
java.util.List<GenericTreeNode> |
getChildren() |
int |
getIndex(GenericTreeNode child) |
int |
getLeafCount() |
GenericTreeNode |
getNextSiblingNode() |
GenericTreeNode |
getParent() |
GenericTreeNode |
getPreviousSiblingNode() |
GenericTreeNode |
getRoot() |
void |
insert(GenericTreeNode child,
int index) |
boolean |
isLeaf() |
boolean |
isRoot() |
void |
remove(GenericTreeNode child) |
void |
remove(int index) |
void |
removeAllChildren() |
public GenericTreeNode getParent()
public GenericTreeNode getRoot()
public boolean isRoot()
public <T> T getAttribute(java.lang.Class<T> clazz)
public void addAttribute(java.lang.Object attribute)
public java.util.List<GenericTreeNode> getChildren()
public int getChildCount()
public boolean isLeaf()
public void add(GenericTreeNode child)
public void insert(GenericTreeNode child, int index) throws java.lang.IndexOutOfBoundsException
java.lang.IndexOutOfBoundsException
public void removeAllChildren()
public void remove(int index) throws java.lang.IndexOutOfBoundsException
java.lang.IndexOutOfBoundsException
public void remove(GenericTreeNode child) throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException
public GenericTreeNode getChildAt(int index) throws java.lang.IndexOutOfBoundsException
java.lang.IndexOutOfBoundsException
public int getIndex(GenericTreeNode child)
public GenericTreeNode getPreviousSiblingNode()
public GenericTreeNode getNextSiblingNode()
public int getDepth()
public int getLeafCount()