Class TreeLayoutObserver.TreeListener
java.lang.Object
org.eclipse.zest.layouts.algorithms.TreeLayoutObserver.TreeListener
- Enclosing class:
- TreeLayoutObserver
A superclass for listeners that can be added to this observer to get
 notification whenever the tree structure changes.
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionprotected voiddefaultHandle(TreeLayoutObserver.TreeNode changedNode) A convenience method that can be overridden if a listener reacts the same way to all events.voidnodeAdded(TreeLayoutObserver.TreeNode newNode) Called when new node is added to the tree structure.voidnodeRemoved(TreeLayoutObserver.TreeNode removedNode) Called when a node is removed from the tree structure.voidparentChanged(TreeLayoutObserver.TreeNode node, TreeLayoutObserver.TreeNode previousParent) Called when a node changes its parent.
- 
Constructor Details- 
TreeListenerpublic TreeListener()
 
- 
- 
Method Details- 
nodeAddedCalled when new node is added to the tree structure. The new node will not have any connections, so it will be a child ofSuper Root- Parameters:
- newNode- the added node
 
- 
nodeRemovedCalled when a node is removed from the tree structure. The given node no longer exists in the tree at the moment of call.- Parameters:
- removedNode- the removed node
 
- 
parentChangedpublic void parentChanged(TreeLayoutObserver.TreeNode node, TreeLayoutObserver.TreeNode previousParent) Called when a node changes its parent.- Parameters:
- node- node that changes its parent
- previousParent- previous parent of the node
 
- 
defaultHandleA convenience method that can be overridden if a listener reacts the same way to all events. By default it's called in every event handler and does nothing.- Parameters:
- changedNode- the node that has changed
 
 
-