poison.core.eventobserver
Source
Module for event observation.
Authors:
Jacob Jensen
License:
https://github.com/PoisonEngine/poison-ui/blob/master/LICENSE
public:
public class EventObserver
public:
An observer for events.
public void subscribe(TEventArgs : EventArgs)(string eventName, EventHandler!TEventArgs handler);
Subscribes an event handler to an event.
Parameters:
eventName The event to subscribe to.
handler The event handler.
public void unsubscribe(string eventName);
Unsubscribes an event.
Parameters:
eventName The name of the event to unsubscribe.
public void fireEvent(TEventArgs : EventArgs)(string eventName, TEventArgs eventArgs);
Fires an event.
Parameters:
eventName The name of the event to fire.
eventArgs The event args to pass.
public static void subscribeGlobal(TEventArgs : EventArgs)(string eventName, EventHandler!TEventArgs handler);
Subscribes a global event handler to an event.
Parameters:
eventName The event to subscribe to.
handler The event handler.
public static void unsubscribeGlobal(string eventName);
Unsubscribes a global event.
Parameters:
eventName The name of the event to unsubscribe.
public static void fireEventGlobal(TEventArgs : EventArgs)(string eventName, TEventArgs eventArgs);
Fires a global event.
Parameters:
eventName The name of the event to fire.
eventArgs The event args to pass.
Generated by venom - Poison Engine's Documentation Generator
Module for event observation.
Authors:
Jacob JensenLicense:
https://github.com/PoisonEngine/poison-ui/blob/master/LICENSEpublic class EventObserver
public:
An observer for events.
public void subscribe(TEventArgs : EventArgs)(string eventName, EventHandler!TEventArgs handler);
Subscribes an event handler to an event.
Parameters:
eventName | The event to subscribe to. |
handler | The event handler. |
public void unsubscribe(string eventName);
Unsubscribes an event.
Parameters:
eventName | The name of the event to unsubscribe. |
public void fireEvent(TEventArgs : EventArgs)(string eventName, TEventArgs eventArgs);
Fires an event.
Parameters:
eventName | The name of the event to fire. |
eventArgs | The event args to pass. |
public static void subscribeGlobal(TEventArgs : EventArgs)(string eventName, EventHandler!TEventArgs handler);
Subscribes a global event handler to an event.
Parameters:
eventName | The event to subscribe to. |
handler | The event handler. |
public static void unsubscribeGlobal(string eventName);
Unsubscribes a global event.
Parameters:
eventName | The name of the event to unsubscribe. |
public static void fireEventGlobal(TEventArgs : EventArgs)(string eventName, TEventArgs eventArgs);
Fires a global event.
Parameters:
eventName | The name of the event to fire. |
eventArgs | The event args to pass. |