APIdia Launch Partner
Top Description Methods
javax.swing.event

public Interface TreeWillExpandListener

extends EventListener
Imports
java.util.EventListener, javax.swing.tree.ExpandVetoException

The listener that's notified when a tree expands or collapses a node. For further information and examples see How to Write a Tree-Will-Expand Listener, a section in The Java Tutorial.
Author
Scott Violet

Method Summary

Modifier and TypeMethod and Description
public void
treeWillCollapse(TreeExpansionEvent
a TreeExpansionEvent containing a TreePath object for the node
event
)

Invoked whenever a node in the tree is about to be collapsed.

public void
treeWillExpand(TreeExpansionEvent
a TreeExpansionEvent containing a TreePath object for the node
event
)

Invoked whenever a node in the tree is about to be expanded.

Method Detail

treeWillCollapseback to summary
public void treeWillCollapse(TreeExpansionEvent event) throws ExpandVetoException

Invoked whenever a node in the tree is about to be collapsed.

Parameters
event:TreeExpansionEvent

a TreeExpansionEvent containing a TreePath object for the node

Exceptions
ExpandVetoException:
to signify collapse has been canceled
treeWillExpandback to summary
public void treeWillExpand(TreeExpansionEvent event) throws ExpandVetoException

Invoked whenever a node in the tree is about to be expanded.

Parameters
event:TreeExpansionEvent

a TreeExpansionEvent containing a TreePath object for the node

Exceptions
ExpandVetoException:
to signify expansion has been canceled