|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.limegroup.gnutella.gui.statistics.StatisticsTreeNode
This class acts as a proxy and as a "decorator" for an underlying instance of a MutableTreeNode implementation.
This class includes the most of the functionality of a DefaultMutableTreeNode, which it simply wraps, without the coupling that directly subclassing DefaultMutableTreeNode would incur.
Method Summary | |
void |
add(StatisticsTreeNode newChild)
Removes newChild from its parent and makes it a child of this node by adding it to the end of this node's child array. |
java.util.Enumeration |
children()
Returns the children of the reciever as an Enumeration. |
boolean |
getAllowsChildren()
Returns true if the receiver allows children. |
javax.swing.tree.TreeNode |
getChildAt(int childIndex)
Returns the child TreeNode at index childIndex. |
int |
getChildCount()
Returns the number of children TreeNodes the receiver contains. |
int |
getIndex(javax.swing.tree.TreeNode node)
Returns the index of node in the receivers children. |
javax.swing.tree.TreeNode |
getParent()
Returns the parent TreeNode of the receiver. |
StatisticsPane |
getStatsPane()
Accessor for the StatisticsPane that contains display data. |
java.lang.String |
getTitleKey()
Returns the String denoting both the title of the node as well as the unique identifying String for the node. |
void |
insert(javax.swing.tree.MutableTreeNode child,
int index)
Adds child to the receiver at index. |
boolean |
isLeaf()
Returns true if the receiver is a leaf. |
boolean |
isRoot()
Returns true if the receiver is the root node. |
void |
remove(int index)
Removes the child at index from the receiver. |
void |
remove(javax.swing.tree.MutableTreeNode node)
Removes node from the receiver. |
void |
removeFromParent()
Removes the receiver from its parent. |
void |
setParent(javax.swing.tree.MutableTreeNode newParent)
Sets the parent of the receiver to newParent. |
void |
setUserObject(java.lang.Object object)
Resets the user object of the receiver to object. |
java.lang.String |
toString()
Defines the class' representation as a String object, used in determining how it is displayed in the JTree. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Method Detail |
public void add(StatisticsTreeNode newChild)
Serves as a proxy for the add method of the wrapped DefaultMutableTreeNode instance.
newChild
- node to add as a child of this node
java.lang.IllegalArgumentException
- if newChild is null
java.lang.IllegalStateException
- if this node does not allow
childrenpublic javax.swing.tree.TreeNode getChildAt(int childIndex)
getChildAt
in interface javax.swing.tree.TreeNode
public int getChildCount()
getChildCount
in interface javax.swing.tree.TreeNode
public javax.swing.tree.TreeNode getParent()
getParent
in interface javax.swing.tree.TreeNode
public int getIndex(javax.swing.tree.TreeNode node)
getIndex
in interface javax.swing.tree.TreeNode
public boolean getAllowsChildren()
getAllowsChildren
in interface javax.swing.tree.TreeNode
public boolean isLeaf()
isLeaf
in interface javax.swing.tree.TreeNode
public java.util.Enumeration children()
children
in interface javax.swing.tree.TreeNode
public void insert(javax.swing.tree.MutableTreeNode child, int index)
insert
in interface javax.swing.tree.MutableTreeNode
public void remove(int index)
remove
in interface javax.swing.tree.MutableTreeNode
public void remove(javax.swing.tree.MutableTreeNode node)
remove
in interface javax.swing.tree.MutableTreeNode
public void setUserObject(java.lang.Object object)
setUserObject
in interface javax.swing.tree.MutableTreeNode
public void removeFromParent()
removeFromParent
in interface javax.swing.tree.MutableTreeNode
public void setParent(javax.swing.tree.MutableTreeNode newParent)
setParent
in interface javax.swing.tree.MutableTreeNode
public boolean isRoot()
public java.lang.String toString()
public java.lang.String getTitleKey()
public StatisticsPane getStatsPane()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |