1 | <?php |
||
14 | class MemoryEventQueue implements EventQueueInterface |
||
15 | { |
||
16 | /** |
||
17 | * @var EventInterface[] |
||
18 | */ |
||
19 | private $events = []; |
||
20 | |||
21 | /** |
||
22 | * Push event to queue. |
||
23 | * |
||
24 | * @param EventInterface $event |
||
25 | * |
||
26 | * @return bool |
||
27 | */ |
||
28 | public function push(EventInterface $event) |
||
34 | |||
35 | /** |
||
36 | * Pop event from queue. Return NULL if queue is empty. |
||
37 | * |
||
38 | * @return EventInterface|null |
||
39 | */ |
||
40 | public function pop() |
||
44 | } |
||
45 |