beowulf.model.tree
Class TreeNode

java.lang.Object
  extended bybeowulf.model.tree.TreeNode

public class TreeNode
extends Object

Version:
1.0, 11/15/2003
Author:
Andy Scukanec (ags at cs dot cornell dot edu)

Field Summary
protected  Vector children
          Holds the list of child nodes.
protected  TreeNode parent
          Holds a reference to the parent node.
protected  Comparable value
          Holds the a reference to the value of this node.
 
Constructor Summary
TreeNode(Comparable newValue)
           
 
Method Summary
 void addChild(TreeNode newChild)
           
 boolean equals(Object o)
           
 TreeNode getChildAt(int index)
           
 int getChildCount()
           
 Enumeration getChildren()
           
 TreeNode getParent()
           
 Comparable getValue()
           
 void removeChild(TreeNode oldChild)
           
 void setParent(TreeNode newParent)
           
 void setValue(Comparable newValue)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

parent

protected TreeNode parent
Holds a reference to the parent node.


value

protected Comparable value
Holds the a reference to the value of this node.


children

protected Vector children
Holds the list of child nodes.

Constructor Detail

TreeNode

public TreeNode(Comparable newValue)
Method Detail

getValue

public Comparable getValue()

setValue

public void setValue(Comparable newValue)

getParent

public TreeNode getParent()

setParent

public void setParent(TreeNode newParent)

getChildCount

public int getChildCount()

getChildren

public Enumeration getChildren()

getChildAt

public TreeNode getChildAt(int index)

addChild

public void addChild(TreeNode newChild)

removeChild

public void removeChild(TreeNode oldChild)

toString

public String toString()

equals

public boolean equals(Object o)