| Package | com.yworks.graph.model |
| Class | public class NodeHierarchyEvent |
| Inheritance | NodeHierarchyEvent flash.events.Event |
INodeHierarchys to notify
listeners of changes to the hierarchy.
| Property | Defined By | ||
|---|---|---|---|
| item : INode [read-only]
Yields the item that is the subject of this event. | NodeHierarchyEvent | ||
| newParent : INode [read-only]
Yields the new parent of the item, if applicable. | NodeHierarchyEvent | ||
| oldParent : INode [read-only]
Yields the old parent of the item, if applicable. | NodeHierarchyEvent | ||
| Method | Defined By | ||
|---|---|---|---|
NodeHierarchyEvent(item:INode, oldParent:INode, newParent:INode, type:String, bubbles:Boolean = false, cancelable:Boolean = false)
Creates a new instance of the event using the provided parameters. | NodeHierarchyEvent | ||
clone():Event [override]
| NodeHierarchyEvent | ||
[static]
Factory method that creates an event for itemAdded notifications. | NodeHierarchyEvent | ||
[static]
Factory method that creates an event for itemChanged notifications. | NodeHierarchyEvent | ||
[static]
Factory method that creates an event for itemMoved notifications. | NodeHierarchyEvent | ||
[static]
Factory method that creates an event for itemRemoved notifications. | NodeHierarchyEvent | ||
| Constant | Defined By | ||
|---|---|---|---|
| ITEM_ADDED : String = itemAdded [static]
Event that will be triggered if an item has been added to a hierarchy model. | NodeHierarchyEvent | ||
| ITEM_CHANGED : String = itemChanged [static]
Event that will be triggered if an item has changed somehow in a hierarchy model. | NodeHierarchyEvent | ||
| ITEM_MOVED : String = itemMoved [static]
Event that will be triggered if an item has been reparented in a hierarchy model. | NodeHierarchyEvent | ||
| ITEM_REMOVED : String = itemRemoved [static]
Event that will be triggered if an item has been removed from a hierarchy model. | NodeHierarchyEvent | ||
| item | property |
item:INode [read-only] Yields the item that is the subject of this event.
public function get item():INode| newParent | property |
newParent:INode [read-only]
Yields the new parent of the item, if applicable.
public function get newParent():INode| oldParent | property |
oldParent:INode [read-only]
Yields the old parent of the item, if applicable.
public function get oldParent():INode| NodeHierarchyEvent | () | Constructor |
public function NodeHierarchyEvent(item:INode, oldParent:INode, newParent:INode, type:String, bubbles:Boolean = false, cancelable:Boolean = false)Creates a new instance of the event using the provided parameters.
Parametersitem:INode | |
oldParent:INode | |
newParent:INode | |
type:String | |
bubbles:Boolean (default = false) | |
cancelable:Boolean (default = false) |
See also
| clone | () | method |
override public function clone():EventReturns
Event |
| createItemAdded | () | method |
public static function createItemAdded(item:INode, newParent:INode):NodeHierarchyEvent
Factory method that creates an event for itemAdded notifications.
Parameters
item:INode — The item that has been added.
| |
newParent:INode — The new parent.
|
NodeHierarchyEvent — A new NodeHierarchyEvent.
|
| createItemChanged | () | method |
public static function createItemChanged(item:INode, parent:INode):NodeHierarchyEvent
Factory method that creates an event for itemChanged notifications.
Parameters
item:INode — The item that has been changed.
| |
parent:INode — The current parent.
|
NodeHierarchyEvent — A new NodeHierarchyEvent.
|
| createItemMoved | () | method |
public static function createItemMoved(item:INode, oldParent:INode, newParent:INode):NodeHierarchyEvent
Factory method that creates an event for itemMoved notifications.
Parameters
item:INode — The item that has been reparented.
| |
oldParent:INode — The old parent.
| |
newParent:INode — The new parent.
|
NodeHierarchyEvent — A new NodeHierarchyEvent.
|
| createItemRemoved | () | method |
public static function createItemRemoved(item:INode, oldParent:INode):NodeHierarchyEvent
Factory method that creates an event for itemRemoved notifications.
Parameters
item:INode — The item that has been removed.
| |
oldParent:INode — The last valid parent.
|
NodeHierarchyEvent — A new NodeHierarchyEvent.
|
| ITEM_ADDED | Constant |
public static const ITEM_ADDED:String = itemAddedEvent that will be triggered if an item has been added to a hierarchy model.
| ITEM_CHANGED | Constant |
public static const ITEM_CHANGED:String = itemChangedEvent that will be triggered if an item has changed somehow in a hierarchy model.
| ITEM_MOVED | Constant |
public static const ITEM_MOVED:String = itemMovedEvent that will be triggered if an item has been reparented in a hierarchy model.
| ITEM_REMOVED | Constant |
public static const ITEM_REMOVED:String = itemRemovedEvent that will be triggered if an item has been removed from a hierarchy model.