Method | Defined By | ||
---|---|---|---|
Subscribes a listener for the signal. | ISignal | ||
![]() |
Subscribes a one-time listener for this signal. | IOnceSignal | |
![]() | dispatch(... valueObjects):void
Dispatches an object to listeners. | IOnceSignal | |
![]() |
Unsubscribes a listener from the signal. | IOnceSignal | |
![]() | removeAll():void
Unsubscribes all listeners from the signal. | IOnceSignal |
add | () | method |
public function add(listener:Function):ISlot
Subscribes a listener for the signal.
Parameters
listener:Function — A function with arguments
that matches the value classes dispatched by the signal.
If value classes are not specified (e.g. via Signal constructor), dispatch() can be called without arguments.
|
ISlot — a ISlot, which contains the Function passed as the parameter
|