borland Packages Class Hierarchy jbcl.view Package Index
java.lang.Object +----java.util.EventObject +----borland.jbcl.util.DispatchableEvent +----borland.jbcl.view.TreeEvent
Variables Constructors Properties Methods
Implements Serializable
The TreeEvent is the object created whenever a tree item event occurs.
The ID property specifies whether the event object was created in response to a NODE_COLLAPSED event or to a NODE_EXPANDED event. Based upon this id, the dispatch() method calls the appropriate method in the listening component, which is either nodeCollapsed() or nodeExpanded(). The location property indicates the node where the event occurred.
public static final int NODE_COLLAPSED = 1001
public static final int NODE_EXPANDED = 1000
public TreeEvent(java.lang.Object source, int id, borland.jbcl.model.GraphLocation node)Constructs a TreeItemEvent object with properties defined in its parameters.
Parameters:
public int getID()Read-only property that returns the event type. Valid values for this property are NODE_EXPANDED and NODE_COLLAPSED.
public GraphLocation getLocation()Read-only property that returns the item where the event occurred.
public void dispatch(java.util.EventListener listener)Checks the id property and sends copies of the event object to registered model event listeners, calling the nodeCollapsed() or nodeExpanded() methods as appropriate.
Overrides: borland.jbcl.util.DispatchableEvent.dispatch(java.util.EventListener)
protected String paramString()Appends TreeEvent parameters to the superclass paramString() method. The parameter string that is appended is:
"id=" + idStr + ",location=" + node
The value of idStr is one of the variables displayed as a string.
Overrides: borland.jbcl.util.DispatchableEvent.paramString()