@@ -34,7 +34,7 @@ |
||
| 34 | 34 | */ |
| 35 | 35 | interface CommandDispatchInterceptorInterface |
| 36 | 36 | { |
| 37 | - /** |
|
| 37 | + /** |
|
| 38 | 38 | * Invoked each time a command is about to be dispatched on a Command Bus. The given <code>commandMessage</code> |
| 39 | 39 | * represents the command being dispatched. |
| 40 | 40 | * |
@@ -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\CommandHandling\Distributed; |
| 10 | 10 | |
@@ -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\CommandHandling\Distributed; |
| 10 | 10 | |
@@ -39,9 +39,9 @@ |
||
| 39 | 39 | */ |
| 40 | 40 | private $annotation; |
| 41 | 41 | |
| 42 | - /** |
|
| 43 | - * @var \ReflectionParameter |
|
| 44 | - */ |
|
| 42 | + /** |
|
| 43 | + * @var \ReflectionParameter |
|
| 44 | + */ |
|
| 45 | 45 | private $parameter; |
| 46 | 46 | |
| 47 | 47 | public function __construct(MetaData $annotation, \ReflectionParameter $parameter) |
@@ -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\EventHandling; |
| 10 | 10 | |
@@ -67,18 +67,18 @@ |
||
| 67 | 67 | |
| 68 | 68 | } |
| 69 | 69 | |
| 70 | - /** |
|
| 71 | - * Creates a snapshot event for an aggregate of the given <code>typeIdentifier</code> of which passed events are |
|
| 72 | - * available in the given <code>eventStream</code>. May return <code>null</code> to indicate a snapshot event is |
|
| 73 | - * not necessary or appropriate for the given event stream. |
|
| 74 | - * |
|
| 75 | - * @param string $typeIdentifier The aggregate's type identifier |
|
| 76 | - * @param mixed $aggregateIdentifier The identifier of the aggregate to create a snapshot for |
|
| 77 | - * @param DomainEventStreamInterface $eventStream The event stream containing the aggregate's past events |
|
| 78 | - * @return DomainEventMessageInterface the snapshot event for the given events, or <code>null</code> if none should be stored. |
|
| 79 | - */ |
|
| 70 | + /** |
|
| 71 | + * Creates a snapshot event for an aggregate of the given <code>typeIdentifier</code> of which passed events are |
|
| 72 | + * available in the given <code>eventStream</code>. May return <code>null</code> to indicate a snapshot event is |
|
| 73 | + * not necessary or appropriate for the given event stream. |
|
| 74 | + * |
|
| 75 | + * @param string $typeIdentifier The aggregate's type identifier |
|
| 76 | + * @param mixed $aggregateIdentifier The identifier of the aggregate to create a snapshot for |
|
| 77 | + * @param DomainEventStreamInterface $eventStream The event stream containing the aggregate's past events |
|
| 78 | + * @return DomainEventMessageInterface the snapshot event for the given events, or <code>null</code> if none should be stored. |
|
| 79 | + */ |
|
| 80 | 80 | protected abstract function createSnapshot($typeIdentifier, $aggregateIdentifier, |
| 81 | - DomainEventStreamInterface $eventStream); |
|
| 81 | + DomainEventStreamInterface $eventStream); |
|
| 82 | 82 | |
| 83 | 83 | |
| 84 | 84 | /** |
@@ -34,15 +34,15 @@ |
||
| 34 | 34 | */ |
| 35 | 35 | interface EventSourcedEntityInterface |
| 36 | 36 | { |
| 37 | - /** |
|
| 38 | - * Register the aggregate root with this entity. The entity must use this aggregate root to apply Domain Events. |
|
| 39 | - * The aggregate root is responsible for tracking all applied events. |
|
| 40 | - * <p/> |
|
| 41 | - * A parent entity is responsible for invoking this method on its child entities prior to propagating events to it. |
|
| 42 | - * Typically, this means all entities have their aggregate root set before any actions are taken on it. |
|
| 43 | - * |
|
| 44 | - * @param AbstractEventSourcedAggregateRoot $aggregateRootToRegister the root of the aggregate this entity is part of. |
|
| 45 | - */ |
|
| 37 | + /** |
|
| 38 | + * Register the aggregate root with this entity. The entity must use this aggregate root to apply Domain Events. |
|
| 39 | + * The aggregate root is responsible for tracking all applied events. |
|
| 40 | + * <p/> |
|
| 41 | + * A parent entity is responsible for invoking this method on its child entities prior to propagating events to it. |
|
| 42 | + * Typically, this means all entities have their aggregate root set before any actions are taken on it. |
|
| 43 | + * |
|
| 44 | + * @param AbstractEventSourcedAggregateRoot $aggregateRootToRegister the root of the aggregate this entity is part of. |
|
| 45 | + */ |
|
| 46 | 46 | public function registerAggregateRoot(AbstractEventSourcedAggregateRoot $aggregateRootToRegister); |
| 47 | 47 | |
| 48 | 48 | /** |
@@ -33,12 +33,12 @@ |
||
| 33 | 33 | */ |
| 34 | 34 | interface SnapshotterInterface |
| 35 | 35 | {
|
| 36 | - /** |
|
| 37 | - * Schedules snapshot taking for an aggregate with given <code>typeIdentifier</code> and |
|
| 38 | - * <code>aggregateIdentifier</code>. |
|
| 39 | - * |
|
| 40 | - * @param string $typeIdentifier the type of the aggregate to take the snapshot for |
|
| 41 | - * @param mixed $aggregateIdentifier The identifier of the aggregate to take the snapshot for |
|
| 42 | - */ |
|
| 36 | + /** |
|
| 37 | + * Schedules snapshot taking for an aggregate with given <code>typeIdentifier</code> and |
|
| 38 | + * <code>aggregateIdentifier</code>. |
|
| 39 | + * |
|
| 40 | + * @param string $typeIdentifier the type of the aggregate to take the snapshot for |
|
| 41 | + * @param mixed $aggregateIdentifier The identifier of the aggregate to take the snapshot for |
|
| 42 | + */ |
|
| 43 | 43 | public function scheduleSnapshot($typeIdentifier, $aggregateIdentifier); |
| 44 | 44 | } |
@@ -37,13 +37,13 @@ |
||
| 37 | 37 | class FilesystemSnapshotEventReader |
| 38 | 38 | { |
| 39 | 39 | |
| 40 | - /** |
|
| 41 | - * @var \SplFileObject |
|
| 42 | - */ |
|
| 40 | + /** |
|
| 41 | + * @var \SplFileObject |
|
| 42 | + */ |
|
| 43 | 43 | private $eventFile; |
| 44 | - /** |
|
| 45 | - * @var \SplFileObject |
|
| 46 | - */ |
|
| 44 | + /** |
|
| 45 | + * @var \SplFileObject |
|
| 46 | + */ |
|
| 47 | 47 | private $snapshotEventFile; |
| 48 | 48 | |
| 49 | 49 | /** |