public class GenericTreeNode extends Object
| Constructor and Description |
|---|
GenericTreeNode() |
| Modifier and Type | Method and Description |
|---|---|
void |
add(GenericTreeNode child) |
int |
getDepth() |
GenericTreeNode |
getChildAt(int index) |
int |
getChildCount() |
List<GenericTreeNode> |
getChildren() |
int |
getIndex(GenericTreeNode child) |
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 List<GenericTreeNode> getChildren()
public int getChildCount()
public boolean isLeaf()
public void add(GenericTreeNode child)
public void insert(GenericTreeNode child, int index) throws IndexOutOfBoundsException
IndexOutOfBoundsExceptionpublic void removeAllChildren()
public void remove(int index)
throws IndexOutOfBoundsException
IndexOutOfBoundsExceptionpublic void remove(GenericTreeNode child) throws IllegalArgumentException
IllegalArgumentExceptionpublic GenericTreeNode getChildAt(int index) throws IndexOutOfBoundsException
IndexOutOfBoundsExceptionpublic int getIndex(GenericTreeNode child)
public GenericTreeNode getPreviousSiblingNode()
public GenericTreeNode getNextSiblingNode()
public int getDepth()
Copyright © 2015. All rights reserved.