fri.gui.swing.polytreetable
Interface PolyTreeNode

All Known Subinterfaces:
MutablePolyTreeNode
All Known Implementing Classes:
AbstractPolyTreeNode, DefaultPolyTreeNode

public interface PolyTreeNode

A PolyTreeNode that has multiple parents and children.
The TreeNode interface is rewritten here because of following reasons:

Nevertheless most method names of PolyTreeNode match those of TreeNode and implement the same semantics.

Author:
Ritzberger Fritz

Method Summary
 java.util.Enumeration children()
          Returns the children of the reciever as an Enumeration.
 boolean getAllowsChildren()
          Returns true if the receiver allows children.
 boolean getAllowsParents()
          Returns true if the receiver allows parents.
 PolyTreeNode getChildAt(int childIndex)
          Returns the parent PolyTreeNode at index childIndex.
 int getChildCount()
          Returns the number of children PolyTreeNodes the receiver contains.
 int getChildIndex(PolyTreeNode node)
          Returns the index of node in the receivers parents.
 PolyTreeNode getParentAt(int parentIndex)
          Returns the parent PolyTreeNode at index parentIndex.
 int getParentCount()
          Returns the number of parents PolyTreeNodes the receiver contains.
 int getParentIndex(PolyTreeNode node)
          Returns the index of node in the receivers parents.
 java.lang.Object getUserObject()
          Returns the userObject, a File or Document or whatever.
 boolean isChildLeaf()
          Returns true if this node has no children.
 boolean isParentLeaf()
          Returns true if this node has no parents.
 java.util.Enumeration parents()
          Returns the parents of the reciever as an Enumeration.
 

Method Detail

getUserObject

public java.lang.Object getUserObject()
Returns the userObject, a File or Document or whatever.


parents

public java.util.Enumeration parents()
Returns the parents of the reciever as an Enumeration.


getAllowsParents

public boolean getAllowsParents()
Returns true if the receiver allows parents.


getParentAt

public PolyTreeNode getParentAt(int parentIndex)
Returns the parent PolyTreeNode at index parentIndex.


getParentCount

public int getParentCount()
Returns the number of parents PolyTreeNodes the receiver contains.


getParentIndex

public int getParentIndex(PolyTreeNode node)
Returns the index of node in the receivers parents.


isParentLeaf

public boolean isParentLeaf()
Returns true if this node has no parents.


isChildLeaf

public boolean isChildLeaf()
Returns true if this node has no children.


getChildIndex

public int getChildIndex(PolyTreeNode node)
Returns the index of node in the receivers parents.


getChildCount

public int getChildCount()
Returns the number of children PolyTreeNodes the receiver contains.


getChildAt

public PolyTreeNode getChildAt(int childIndex)
Returns the parent PolyTreeNode at index childIndex.


getAllowsChildren

public boolean getAllowsChildren()
Returns true if the receiver allows children.


children

public java.util.Enumeration children()
Returns the children of the reciever as an Enumeration.