Ejemplo n.º 1
0
 internal void Apply(CustomerCreatedEvent @event)
 {
     Id = @event.CustomerId;
     _firstName = @event.FirstName;
     _lastName = @event.LastName;
     _email = @event.Email;
 }
Ejemplo n.º 2
0
 public Customer(CreateCustomerCommand command)
 {
     var customerCreatedEvent = new CustomerCreatedEvent(command.CustomerId, command.FirstName, command.LastName, command.Email);
     RaiseEvent(customerCreatedEvent);
 }