| Total Complexity | 4 |
| Total Lines | 44 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 17 | class EventRecorder implements EventRecorderInterface |
||
| 18 | { |
||
| 19 | /** |
||
| 20 | * @var Event[] |
||
| 21 | */ |
||
| 22 | private $recordedEvents; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * @return mixed |
||
| 26 | */ |
||
| 27 | public function clear() |
||
| 28 | { |
||
| 29 | $this->recordedEvents = []; |
||
| 30 | } |
||
| 31 | |||
| 32 | /** |
||
| 33 | * @param AggregateUuid $eventUuid |
||
| 34 | * @return mixed |
||
| 35 | */ |
||
| 36 | public function delete(AggregateUuid $eventUuid) |
||
| 39 | } |
||
| 40 | |||
| 41 | /** |
||
| 42 | * @param Event $event |
||
| 43 | * |
||
| 44 | * @return mixed |
||
| 45 | */ |
||
| 46 | public function record(Event $event) |
||
| 47 | { |
||
| 48 | $eventUuid = $event->uuid(); |
||
| 49 | $this->recordedEvents[(string) $eventUuid] = $event; |
||
| 50 | } |
||
| 51 | |||
| 52 | /** |
||
| 53 | * @return Event[] |
||
| 54 | */ |
||
| 55 | public function releaseEvents() |
||
| 61 | } |
||
| 62 | } |
||
| 63 |