net.sourceforge.mewt.tree
Class Node

java.lang.Object
  extended by net.sourceforge.mewt.tree.Node

public class Node
extends java.lang.Object

The Class Node.


Constructor Summary
Node(Node parent, java.lang.Object o)
          Instantiates a new node.
 
Method Summary
 void addChild(Node child)
          Adds the child.
 Node getChildAt(int i)
          Gets the child at.
 int getChildCount()
          Gets the child count.
 java.lang.Object getUserObject()
          Gets the user object.
 boolean isExpanded()
          Checks if is expanded.
 boolean isLeaf()
          Checks if is leaf.
 void removeAll()
          Removes the all.
 void removeChild(Node child)
          Removes the child.
 void setExpanded(boolean exp)
          Sets the expanded.
 void setLeaf(boolean l)
          Sets the leaf.
 void setUserObject(java.lang.Object o)
          Sets the user object.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Node

public Node(Node parent,
            java.lang.Object o)
Instantiates a new node.

Parameters:
parent - the parent
o - the o
Method Detail

addChild

public void addChild(Node child)
Adds the child.

Parameters:
child - the child

removeChild

public void removeChild(Node child)
Removes the child.

Parameters:
child - the child

removeAll

public void removeAll()
Removes the all.


isLeaf

public boolean isLeaf()
Checks if is leaf.

Returns:
true, if is leaf

setLeaf

public void setLeaf(boolean l)
Sets the leaf.

Parameters:
l - the new leaf

getChildCount

public int getChildCount()
Gets the child count.

Returns:
the child count

getUserObject

public java.lang.Object getUserObject()
Gets the user object.

Returns:
the user object

setUserObject

public void setUserObject(java.lang.Object o)
Sets the user object.

Parameters:
o - the new user object

getChildAt

public Node getChildAt(int i)
Gets the child at.

Parameters:
i - the i
Returns:
the child at

isExpanded

public boolean isExpanded()
Checks if is expanded.

Returns:
true, if is expanded

setExpanded

public void setExpanded(boolean exp)
Sets the expanded.

Parameters:
exp - the new expanded