Ddd\Infrastructure\Application\Notification\DoctrineEventStore::append PHP Method

append() public method

public append ( $aDomainEvent )
    public function append($aDomainEvent)
    {
        $storedEvent = new StoredEvent(get_class($aDomainEvent), $aDomainEvent->occurredOn(), $this->serializer()->serialize($aDomainEvent, 'json'));
        $this->getEntityManager()->persist($storedEvent);
        $this->getEntityManager()->flush($storedEvent);
    }