ch.randelshofer.tree.demo
Class ManyEyesCompositeNode
java.lang.Object
ch.randelshofer.tree.demo.ManyEyesNode
ch.randelshofer.tree.demo.ManyEyesCompositeNode
- All Implemented Interfaces:
- TreeNode
public class ManyEyesCompositeNode
- extends ManyEyesNode
ManyEyesCompositeNode.
- Version:
- 1.0 2009-02-07 Created.
- Author:
- Werner Randelshofer, Staldenmattweg 2, CH-6405 Immensee
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ManyEyesCompositeNode
public ManyEyesCompositeNode(java.lang.String[] values)
children
public java.util.List<TreeNode> children()
- Description copied from interface:
TreeNode
- Returns the children of this node
in a List.
If this object does not have children,
it returns an empty List.
- Specified by:
children in interface TreeNode- Overrides:
children in class ManyEyesNode
- Returns:
- the children of this node
getAllowsChildren
public boolean getAllowsChildren()
- Description copied from interface:
TreeNode
- Returns true, if this node can not have children.
This is used to make a distinction between composite nodes which have
no children, and leaf nodes which can have no children.
- Specified by:
getAllowsChildren in interface TreeNode- Overrides:
getAllowsChildren in class ManyEyesNode
removeAllChildren
public void removeAllChildren()
add
public void add(ManyEyesNode child)
remove
public void remove(ManyEyesNode child)