1 | <?php |
||
18 | class EventDispatcher extends ContainerAwareEventDispatcher |
||
19 | { |
||
20 | |||
21 | /** |
||
22 | * @var EventDispatcherInterface[] |
||
23 | */ |
||
24 | private $catchall = []; |
||
25 | |||
26 | /** |
||
27 | * @Inject({"@service_container"}) |
||
28 | * @param ContainerInterface $container |
||
29 | */ |
||
30 | 8 | public function __construct(ContainerInterface $container) |
|
34 | |||
35 | /** |
||
36 | * @param EventDispatcherInterface $dispatcher |
||
37 | */ |
||
38 | public function addCatchall(EventDispatcherInterface $dispatcher) |
||
42 | |||
43 | /** |
||
44 | * @param string $eventName |
||
45 | * @param Event $event |
||
46 | * @return Event |
||
47 | */ |
||
48 | 2 | public function dispatch($eventName, Event $event = null) |
|
60 | |||
61 | /** |
||
62 | * @param AbstractEvent $event |
||
63 | */ |
||
64 | 4 | public function dispatchEvent(AbstractEvent $event) |
|
72 | |||
73 | /** |
||
74 | * @param AbstractEvent $event |
||
75 | */ |
||
76 | 1 | public function dispatchAsWebsocketEvent(AbstractEvent $event) |
|
82 | |||
83 | /** |
||
84 | * @param AbstractEvent $event |
||
85 | * @param integer|null $timestamp |
||
86 | */ |
||
87 | 2 | public function dispatchInBackground(AbstractEvent $event, $timestamp = 0) |
|
97 | } |
||
98 |