Example #1
0
        public void ChangeName(string firstname, string lastname)
        {
            var @event = new CustomerNameChangedEvent(Id, firstname, lastname, Version);

            ApplyEvent(@event);
            AppendEvent(@event);
        }
Example #2
0
 public void ApplyEvent(CustomerNameChangedEvent @event)
 {
     FirstName = @event.FirstName;
     LastName  = @event.LastName;
     Version   = @event.AppliedVersion;
 }