@@ 70-76 (lines=7) @@ | ||
67 | { |
|
68 | $this->payload = []; |
|
69 | $eventReflection = new \ReflectionClass($event); |
|
70 | foreach ($eventReflection->getProperties() as $property) { |
|
71 | if ('occurredOn' === $property->getName()) { |
|
72 | continue; |
|
73 | } |
|
74 | $property->setAccessible(true); |
|
75 | $this->payload[$property->getName()] = $this->serializePayload($property, $event); |
|
76 | } |
|
77 | $this->payload = json_encode($this->payload); |
|
78 | } |
|
79 | ||
@@ 84-90 (lines=7) @@ | ||
81 | { |
|
82 | $this->serializedEvent = []; |
|
83 | $eventReflection = new \ReflectionClass($event); |
|
84 | foreach ($eventReflection->getProperties() as $property) { |
|
85 | if ('occurredOn' === $property->getName()) { |
|
86 | continue; |
|
87 | } |
|
88 | $property->setAccessible(true); |
|
89 | $this->serializedEvent[$property->getName()] = $this->serializeEvent($property, $event); |
|
90 | } |
|
91 | } |
|
92 | ||
93 | private function setOccurredOn(\DateTimeInterface $occurredOn) : void |