classpathhelper.util
Interface ITree

All Known Subinterfaces:
ITreeRoot
All Known Implementing Classes:
AbstractTree, AbstractTreeRoot

public interface ITree

Interface that defines a basic tree node. This tree is intended to work with a org.eclipse.jface.viewers.ITreeContentProvider and org.eclipse.jface.viewers.ILabelProvider.

In addition to supporting a basic tree relationship, this interface also defines two types of events. A Node Change Event is designed to allow a node to report internal changes, such as attributes or other state changes.

A Structure Change Event refers to changes in terms of parent and children (such as a child added or removed).

Since:
1.0
Author:
bharris

Method Summary
 ITree[] getChildren()
          Getter for this nodes children.
 Image getIconName()
          The associated Icon.
 ITree getParent()
          Getter for the parent of this node.
 boolean hasChildren()
          Does this node have children.
 

Method Detail

hasChildren

public boolean hasChildren()
Does this node have children.

Returns:
true if this node has children otherwise false
Since:
1.0

getChildren

public ITree[] getChildren()
Getter for this nodes children.

Returns:
An array containing this nodes children.
Since:
1.0

getParent

public ITree getParent()
Getter for the parent of this node.

Returns:
The parent node or null if this nood is the root or if this node has not yet been added to a tree.
Since:
1.0

getIconName

public Image getIconName()
The associated Icon.

Returns:
The Icon for this node.
Since:
1.0