XOOPS RMCommon Utilities
2.1.8.91RC
|
Public Member Functions | |
__construct () | |
bindEventListener (Swift_Events_EventListener $listener) | |
createCommandEvent (Swift_Transport $source, $command, $successCodes=array()) | |
createResponseEvent (Swift_Transport $source, $response, $valid) | |
createSendEvent (Swift_Transport $source, Swift_Mime_Message $message) | |
createTransportChangeEvent (Swift_Transport $source) | |
createTransportExceptionEvent (Swift_Transport $source, Swift_TransportException $ex) | |
dispatchEvent (Swift_Events_EventObject $evt, $target) | |
Private Member Functions | |
_bubble (Swift_Events_EventObject $evt, $target) | |
_prepareBubbleQueue (Swift_Events_EventObject $evt) | |
Private Attributes | |
$_bubbleQueue = array() | |
$_eventMap = array() | |
$_listeners = array() | |
Definition at line 27 of file SimpleEventDispatcher.php.
Swift_Events_SimpleEventDispatcher::__construct | ( | ) |
Create a new EventDispatcher.
Definition at line 42 of file SimpleEventDispatcher.php.
|
private |
Bubble $evt up the stack calling $target() on each listener
Definition at line 166 of file SimpleEventDispatcher.php.
References $target, and Swift_Events_EventObject\bubbleCancelled().
Referenced by dispatchEvent().
|
private |
Queue listeners on a stack ready for $evt to be bubbled up it
Definition at line 151 of file SimpleEventDispatcher.php.
Referenced by dispatchEvent().
Swift_Events_SimpleEventDispatcher::bindEventListener | ( | Swift_Events_EventListener | $listener | ) |
Bind an event listener to this dispatcher.
Swift_Events_EventListener | $listener |
Implements Swift_Events_EventDispatcher.
Definition at line 123 of file SimpleEventDispatcher.php.
Swift_Events_SimpleEventDispatcher::createCommandEvent | ( | Swift_Transport | $source, |
$command, | |||
$successCodes = array() |
|||
) |
Create a new CommandEvent for $source and $command.
Swift_Transport | $source | |
string | $command | That will be executed |
array | $successCodes | That are needed |
Implements Swift_Events_EventDispatcher.
Definition at line 74 of file SimpleEventDispatcher.php.
Swift_Events_SimpleEventDispatcher::createResponseEvent | ( | Swift_Transport | $source, |
$response, | |||
$valid | |||
) |
Create a new ResponseEvent for $source and $response.
Swift_Transport | $source | |
string | $response | |
boolean | $valid | If the response is valid |
Implements Swift_Events_EventDispatcher.
Definition at line 88 of file SimpleEventDispatcher.php.
Swift_Events_SimpleEventDispatcher::createSendEvent | ( | Swift_Transport | $source, |
Swift_Mime_Message | $message | ||
) |
Create a new SendEvent for $source and $message.
Swift_Transport | $source | |
Swift_Mime_Message |
Implements Swift_Events_EventDispatcher.
Definition at line 60 of file SimpleEventDispatcher.php.
Swift_Events_SimpleEventDispatcher::createTransportChangeEvent | ( | Swift_Transport | $source | ) |
Create a new TransportChangeEvent for $source.
Swift_Transport | $source |
Implements Swift_Events_EventDispatcher.
Definition at line 100 of file SimpleEventDispatcher.php.
Swift_Events_SimpleEventDispatcher::createTransportExceptionEvent | ( | Swift_Transport | $source, |
Swift_TransportException | $ex | ||
) |
Create a new TransportExceptionEvent for $source.
Swift_Transport | $source | |
Swift_TransportException | $ex |
Implements Swift_Events_EventDispatcher.
Definition at line 112 of file SimpleEventDispatcher.php.
Swift_Events_SimpleEventDispatcher::dispatchEvent | ( | Swift_Events_EventObject | $evt, |
$target | |||
) |
Dispatch the given Event to all suitable listeners.
Swift_Events_EventObject | $evt | |
string | $target | method |
Implements Swift_Events_EventDispatcher.
Definition at line 142 of file SimpleEventDispatcher.php.
References $target, _bubble(), and _prepareBubbleQueue().
|
private |
Listeners queued to have an Event bubbled up the stack to them
Definition at line 37 of file SimpleEventDispatcher.php.
|
private |
A map of event types to their associated listener types
Definition at line 31 of file SimpleEventDispatcher.php.
|
private |
Event listeners bound to this dispatcher
Definition at line 34 of file SimpleEventDispatcher.php.