| Package | org.springextensions.actionscript.core.event |
| SVN browsing | EventBusFacade.as |
| Fisheye | EventBusFacade.as |
| Class | public class EventBusFacade |
| Implements | IEventBus |
IEventBus interface that acts as
a facade for the static EventBus class. Every method is
re-rerouted to the static equivalent in the EventBus class.
Implemented to make mocking the EventBus a little easier.
See also
Documentation reference: the eventbus introduction
| Method | Defined by | ||
|---|---|---|---|
|
Creates a new
EventBusFacade instance. | EventBusFacade | ||
|
addEventClassListener(eventClass:Class, listener:Function, useWeakReference:Boolean = false):void
Adds a listener function for events of a specific
Class. | EventBusFacade | ||
|
addEventClassListenerProxy(eventClass:Class, proxy:MethodInvoker, useWeakReference:Boolean = false):void
Adds a proxied event handler as a listener for events of a specific
Class. | EventBusFacade | ||
|
addEventListener(type:String, listener:Function, useWeakReference:Boolean = false):void
Adds the given listener function as an event handler to the given event type.
| EventBusFacade | ||
|
addEventListenerProxy(type:String, proxy:MethodInvoker, useWeakReference:Boolean = false):void
Adds a proxied event handler as a listener to the specified event type.
| EventBusFacade | ||
|
addListener(listener:IEventBusListener, useWeakReference:Boolean = false):void
Adds the given listener object as a listener to all events send via the event bus.
| EventBusFacade | ||
|
dispatch(type:String):void
Convenience method for dispatching an event.
| EventBusFacade | ||
|
dispatchEvent(event:Event):void
Dispatches the specified
Event on the event bus. | EventBusFacade | ||
|
removeAll():void
Clears the entire
IEventBus by removing all types of listeners. | EventBusFacade | ||
|
removeEventClassListener(eventClass:Class, listener:Function):void
Removes a listener function for events of a specific Class.
| EventBusFacade | ||
|
removeEventClassListenerProxy(eventClass:Class, proxy:MethodInvoker):void
Removes a proxied event handler as a listener for events of a specific
Class. | EventBusFacade | ||
|
removeEventListener(type:String, listener:Function):void
Removes the given listener function as an event handler from the given event type.
| EventBusFacade | ||
|
removeEventListenerProxy(type:String, proxy:MethodInvoker):void
Removes a proxied event handler as a listener from the specified event type.
| EventBusFacade | ||
|
removeListener(listener:IEventBusListener):void
Removes the given listener from the event bus.
| EventBusFacade | ||
| EventBusFacade | () | constructor |
public function EventBusFacade()
Creates a new EventBusFacade instance.
| addEventClassListener | () | method |
public function addEventClassListener(eventClass:Class, listener:Function, useWeakReference:Boolean = false):void
Adds a listener function for events of a specific Class.
eventClass:Class — The specified Class.
|
|
listener:Function — The specified listener function.
|
|
useWeakReference:Boolean (default = false) |
See also
| addEventClassListenerProxy | () | method |
public function addEventClassListenerProxy(eventClass:Class, proxy:MethodInvoker, useWeakReference:Boolean = false):void
Adds a proxied event handler as a listener for events of a specific Class.
eventClass:Class — The specified Class.
|
|
proxy:MethodInvoker — The specified listener function.
|
|
useWeakReference:Boolean (default = false) |
See also
| addEventListener | () | method |
public function addEventListener(type:String, listener:Function, useWeakReference:Boolean = false):voidAdds the given listener function as an event handler to the given event type.
Parameterstype:String — the type of event to listen to
|
|
listener:Function — the event handler function
|
|
useWeakReference:Boolean (default = false) |
See also
| addEventListenerProxy | () | method |
public function addEventListenerProxy(type:String, proxy:MethodInvoker, useWeakReference:Boolean = false):voidAdds a proxied event handler as a listener to the specified event type.
Parameterstype:String — the type of event to listen to
|
|
proxy:MethodInvoker — a proxy method invoker for the event handler
|
|
useWeakReference:Boolean (default = false) |
See also
| addListener | () | method |
public function addListener(listener:IEventBusListener, useWeakReference:Boolean = false):voidAdds the given listener object as a listener to all events send via the event bus.
Parameterslistener:IEventBusListener |
|
useWeakReference:Boolean (default = false) |
See also
| dispatch | () | method |
public function dispatch(type:String):void
Convenience method for dispatching an event. This will create an Event instance with the given
type and call dispatchEvent() on the event bus.
type:String — the type of the event to dispatch
|
See also
| dispatchEvent | () | method |
public function dispatchEvent(event:Event):void
Dispatches the specified Event on the event bus.
event:Event — The specified Event.
|
See also
| removeAll | () | method |
public function removeAll():void
Clears the entire IEventBus by removing all types of listeners.
See also
| removeEventClassListener | () | method |
public function removeEventClassListener(eventClass:Class, listener:Function):voidRemoves a listener function for events of a specific Class.
ParameterseventClass:Class — The specified Class.
|
|
listener:Function — The specified listener function.
|
See also
| removeEventClassListenerProxy | () | method |
public function removeEventClassListenerProxy(eventClass:Class, proxy:MethodInvoker):void
Removes a proxied event handler as a listener for events of a specific Class.
eventClass:Class — The specified Class.
|
|
proxy:MethodInvoker — The specified listener function.
|
See also
| removeEventListener | () | method |
public function removeEventListener(type:String, listener:Function):voidRemoves the given listener function as an event handler from the given event type.
Parameterstype:String |
|
listener:Function |
See also
| removeEventListenerProxy | () | method |
public function removeEventListenerProxy(type:String, proxy:MethodInvoker):voidRemoves a proxied event handler as a listener from the specified event type.
Parameterstype:String |
|
proxy:MethodInvoker |
See also
| removeListener | () | method |
public function removeListener(listener:IEventBusListener):voidRemoves the given listener from the event bus.
Parameterslistener:IEventBusListener |
See also