Exemplo n.º 1
0
 private EventStreamRecord BuildEventStream(IAggregateRoot aggregateRoot, string commandId)
 {
     return new EventStreamRecord()
     {
         AggregateRootId = aggregateRoot.AggregateRootId,
         CommandId = commandId,
         Version = aggregateRoot.Version,
         EventDatas = _binarySerializer.Serialize(aggregateRoot.GetUnCommitEvents())
     };
 }