org.annotation.agschema.graphics.vtree
Interface VTreeExpansionState

All Superinterfaces:
java.util.EventListener, java.beans.PropertyChangeListener
All Known Implementing Classes:
VTreeExpansionStateImpl

public interface VTreeExpansionState
extends java.beans.PropertyChangeListener

Maintains the state of expansion/collapse of the nodes in a tree from the perspective of viewing.

Author:
nikhild

Method Summary
 void addListener(VTreeExpansionListener l)
          Add a listener to receive notification of events
 void collapse(javax.swing.tree.TreeNode node)
          Collapses a node.
 void expand(javax.swing.tree.TreeNode node)
          Expands a node
 javax.swing.tree.TreeNode getRoot()
          Get the root of the tree
 boolean isCollapsed(javax.swing.tree.TreeNode node)
          Returns true iff the node is collapsed
 boolean isExpanded(javax.swing.tree.TreeNode node)
          Returns true iff the node is expanded
 boolean isHidden(javax.swing.tree.TreeNode node)
          Returns true iff an ancestor of the node is collapsed.
 void removeListener(VTreeExpansionListener l)
          Remove the listener
 
Methods inherited from interface java.beans.PropertyChangeListener
propertyChange
 

Method Detail

addListener

public void addListener(VTreeExpansionListener l)
Add a listener to receive notification of events

Parameters:
l - the listener to add

removeListener

public void removeListener(VTreeExpansionListener l)
Remove the listener

Parameters:
l - the listener to remove

getRoot

public javax.swing.tree.TreeNode getRoot()
Get the root of the tree


isExpanded

public boolean isExpanded(javax.swing.tree.TreeNode node)
Returns true iff the node is expanded


isCollapsed

public boolean isCollapsed(javax.swing.tree.TreeNode node)
Returns true iff the node is collapsed


isHidden

public boolean isHidden(javax.swing.tree.TreeNode node)
Returns true iff an ancestor of the node is collapsed.


expand

public void expand(javax.swing.tree.TreeNode node)
Expands a node


collapse

public void collapse(javax.swing.tree.TreeNode node)
Collapses a node.