org.stringtree.util.tree
Class SimpleTree
java.lang.Object
org.stringtree.util.tree.EmptyTree
org.stringtree.util.tree.SimpleTree
- All Implemented Interfaces:
- MutableTree, Tree
- Direct Known Subclasses:
- ProxyTree
public class SimpleTree
- extends EmptyTree
- implements MutableTree
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
parent
protected Tree parent
children
protected java.util.Collection children
value
protected java.lang.Object value
SimpleTree
public SimpleTree(java.lang.Object value)
SimpleTree
public SimpleTree()
SimpleTree
public SimpleTree(Tree parent,
java.util.Collection children,
java.lang.Object value)
getParent
public Tree getParent()
- Specified by:
getParent
in interface Tree
- Overrides:
getParent
in class EmptyTree
setParent
public void setParent(Tree parent)
- Specified by:
setParent
in interface MutableTree
getValue
public java.lang.Object getValue()
- Specified by:
getValue
in interface Tree
- Overrides:
getValue
in class EmptyTree
setValue
public void setValue(java.lang.Object value)
- Specified by:
setValue
in interface MutableTree
getChildren
public java.util.Collection getChildren()
- Specified by:
getChildren
in interface Tree
- Overrides:
getChildren
in class EmptyTree
setChildren
public void setChildren(java.util.Collection children)
ensureChildren
protected void ensureChildren()
addChild
public void addChild(Tree child)
- Specified by:
addChild
in interface MutableTree
removeChild
public void removeChild(Tree child)
- Specified by:
removeChild
in interface MutableTree