@@ -129,6 +129,9 @@ |
||
| 129 | 129 | $this->eventStore->appendEvents($this->getTypeIdentifier(), $eventStream); |
| 130 | 130 | } |
| 131 | 131 | |
| 132 | + /** |
|
| 133 | + * @param string $className |
|
| 134 | + */ |
|
| 132 | 135 | private function validateEventSourcedAggregate($className) |
| 133 | 136 | { |
| 134 | 137 | $reflClass = new \ReflectionClass($className); |
@@ -24,7 +24,6 @@ |
||
| 24 | 24 | |
| 25 | 25 | namespace Governor\Framework\EventSourcing; |
| 26 | 26 | |
| 27 | -use Governor\Framework\Common\ReflectionUtils; |
|
| 28 | 27 | use Governor\Framework\Domain\DomainEventMessageInterface; |
| 29 | 28 | use Governor\Framework\EventSourcing\EventSourcedAggregateRootInterface; |
| 30 | 29 | |
@@ -32,7 +32,7 @@ discard block |
||
| 32 | 32 | |
| 33 | 33 | /** |
| 34 | 34 | * |
| 35 | - * @return \Governor\Framework\Serializer\SerializedDomainEventDataInterface|null |
|
| 35 | + * @return null|SimpleSerializedDomainEventData |
|
| 36 | 36 | * @throws \RuntimeException |
| 37 | 37 | */ |
| 38 | 38 | public function readEventMessage() |
@@ -92,6 +92,9 @@ discard block |
||
| 92 | 92 | ); |
| 93 | 93 | } |
| 94 | 94 | |
| 95 | + /** |
|
| 96 | + * @param integer $length |
|
| 97 | + */ |
|
| 95 | 98 | private function readBytes($length) |
| 96 | 99 | { |
| 97 | 100 | $stream = null; |
@@ -9,7 +9,6 @@ |
||
| 9 | 9 | namespace Governor\Framework\EventStore\Filesystem; |
| 10 | 10 | |
| 11 | 11 | use Governor\Framework\Serializer\SimpleSerializedDomainEventData; |
| 12 | -use Governor\Framework\Serializer\SerializerInterface; |
|
| 13 | 12 | |
| 14 | 13 | /** |
| 15 | 14 | * Description of FilesystemEventMessageReader |
@@ -112,6 +112,10 @@ |
||
| 112 | 112 | return new FilesystemDomainEventStream($file, $this->serializer); |
| 113 | 113 | } |
| 114 | 114 | |
| 115 | + /** |
|
| 116 | + * @param string $type |
|
| 117 | + * @param \SplFileObject $eventFile |
|
| 118 | + */ |
|
| 115 | 119 | private function readSnapshotEvent($type, $identifier, $eventFile) |
| 116 | 120 | { |
| 117 | 121 | $snapshotEvent = null; |
@@ -193,7 +193,7 @@ |
||
| 193 | 193 | * @param mixed $upcasterChain Set of upcasters to use when an event needs upcasting before |
| 194 | 194 | * de-serialization |
| 195 | 195 | * @param bool $skipUnknownTypes whether to skip unknown event types |
| 196 | - * @return DomainEventMessageInterface[] The actual DomainEventMessage instances stored in this entry |
|
| 196 | + * @return GenericDomainEventMessage[] The actual DomainEventMessage instances stored in this entry |
|
| 197 | 197 | */ |
| 198 | 198 | |
| 199 | 199 | public function getDomainEvents( |
@@ -182,7 +182,7 @@ |
||
| 182 | 182 | } |
| 183 | 183 | |
| 184 | 184 | /** |
| 185 | - * @return callable |
|
| 185 | + * @return \Closure |
|
| 186 | 186 | */ |
| 187 | 187 | private function getCursorCallback() |
| 188 | 188 | { |
@@ -1,10 +1,10 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * This file is part of the SmartGecko(c) business platform. |
|
| 4 | - * |
|
| 5 | - * For the full copyright and license information, please view the LICENSE |
|
| 6 | - * file that was distributed with this source code. |
|
| 7 | - */ |
|
| 3 | + * This file is part of the SmartGecko(c) business platform. |
|
| 4 | + * |
|
| 5 | + * For the full copyright and license information, please view the LICENSE |
|
| 6 | + * file that was distributed with this source code. |
|
| 7 | + */ |
|
| 8 | 8 | |
| 9 | 9 | namespace Governor\Framework\EventStore\Mongo; |
| 10 | 10 | |
@@ -188,7 +188,7 @@ discard block |
||
| 188 | 188 | { |
| 189 | 189 | $self = $this; |
| 190 | 190 | |
| 191 | - $cb = function (array $entry, $identifier) use ($self) { |
|
| 191 | + $cb = function(array $entry, $identifier) use ($self) { |
|
| 192 | 192 | return $self->storageStrategy->extractEventMessages( |
| 193 | 193 | $entry, |
| 194 | 194 | $identifier, |
@@ -269,7 +269,7 @@ discard block |
||
| 269 | 269 | //cursor.addOption(Bytes.QUERYOPTION_NOTIMEOUT); |
| 270 | 270 | $self = $this; |
| 271 | 271 | |
| 272 | - $cb = function (array $entry, $identifier) use ($self) { |
|
| 272 | + $cb = function(array $entry, $identifier) use ($self) { |
|
| 273 | 273 | return $self->storageStrategy->extractEventMessages( |
| 274 | 274 | $entry, |
| 275 | 275 | $identifier, |
@@ -81,6 +81,13 @@ |
||
| 81 | 81 | */ |
| 82 | 82 | private $scn; |
| 83 | 83 | |
| 84 | + /** |
|
| 85 | + * @param integer $firstScn |
|
| 86 | + * @param string $id |
|
| 87 | + * @param string $typeId |
|
| 88 | + * @param integer $batchSize |
|
| 89 | + * @param string $domainEventEntryEntityName |
|
| 90 | + */ |
|
| 84 | 91 | public function __construct($firstScn, $id, $typeId, $batchSize, |
| 85 | 92 | $domainEventEntryEntityName, EntityManager $em) |
| 86 | 93 | { |
@@ -40,6 +40,9 @@ |
||
| 40 | 40 | */ |
| 41 | 41 | private $propertyName; |
| 42 | 42 | |
| 43 | + /** |
|
| 44 | + * @param string $propertyName |
|
| 45 | + */ |
|
| 43 | 46 | function __construct($propertyName) |
| 44 | 47 | { |
| 45 | 48 | $this->propertyName = $propertyName; |
@@ -48,6 +48,9 @@ |
||
| 48 | 48 | */ |
| 49 | 49 | private $expression; |
| 50 | 50 | |
| 51 | + /** |
|
| 52 | + * @param string $operator |
|
| 53 | + */ |
|
| 51 | 54 | function __construct(OrmProperty $propertyName, $operator, $expression) |
| 52 | 55 | { |
| 53 | 56 | $this->propertyName = $propertyName; |