1 | <?php |
||
18 | class EventBus implements EventBusInterface |
||
19 | { |
||
20 | /** |
||
21 | * @var LocatorInterface |
||
22 | */ |
||
23 | private $locator; |
||
24 | |||
25 | /** |
||
26 | * @param LocatorInterface $locator |
||
27 | */ |
||
28 | public function __construct(LocatorInterface $locator) |
||
32 | |||
33 | /** |
||
34 | * Publishes the event $event to every EventListener that wants to. |
||
35 | * |
||
36 | * @param EventInterface $event |
||
37 | */ |
||
38 | public function publish(EventInterface $event) |
||
44 | |||
45 | /** |
||
46 | * @param AggregateEventsInterface $aggregator |
||
47 | */ |
||
48 | public function pullAndPublish(AggregateEventsInterface $aggregator) |
||
54 | |||
55 | /** |
||
56 | * @return ListenerInterface[]|ListenerCollection |
||
57 | */ |
||
58 | public function getRegisteredEventListeners() |
||
62 | } |
||
63 |