Event
Module | ejs.events |
Definition | class Event |
Inheritance | Event ![]() |
Stability | Prototype. |
WARNGING: This class is prototype and will be changed in the next release.
The Event class encapsulates information pertaining to a system or application event. Applications typically subclass Event to add custom event data if required. Events are initiated via the EventTarget class and are routed to listening functions via a system event queue.
Properties
Qualifiers | Property | Type | Description |
---|---|---|---|
public static const | PRI_HIGH | Number | High priority constant for use with the Event() constructor method. |
public static const | PRI_LOW | Number | Low priority constant for use with the Event() constructor method. |
public static const | PRI_NORMAL | Number | Normal priority constant for use with the Event() constructor method. |
public | bubbles | Boolean | Whether the event will bubble up to the listeners parent. |
public | data | Object | Event data associated with the Event. When Events are created, the constructor optionally takes an arbitrary object data reference. |
public | priority | Number | Event priority. Priorities are 0-99. Zero is the highest priority and 50 is normal. Use the priority symbolic constants PRI_LOW, PRI_NORMAL or PRI_HIGH. |
public | timestamp | Date | Time the event was created. The Event constructor will automatically set the timestamp to the current time. |
Event Methods
Qualifiers | Method |
---|---|
Event(data: Object = null , bubbles: Boolean = false , priority: Number = PRI_NORMAL) | |
Constructor for Event. | |
public override | toString(): String |
Create a string representation of the event. |
Method Detail
Constructor for Event.
- Description
- Create a new Event object.
override public toString(): String
Create a string representation of the event.
- Returns
- A string of the form: "[Event: EventName]".