public static ClientProfileState BuildStateFromEventHistory(IEnumerable<Event> events) { var aggState = new ClientProfileState(); foreach (var eventThatHappened in events) { aggState.MakeStateRealize((IClientProfileEvent)eventThatHappened); } return aggState; }
public static ClientProfileState BuildStateFromEventHistory(IEnumerable <Event> events) { var aggState = new ClientProfileState(); foreach (var eventThatHappened in events) { aggState.MakeStateRealize((IClientProfileEvent)eventThatHappened); } return(aggState); }
public ClientProfileAggregate(ClientProfileState aggStateBeforeChanges) { _aggState = aggStateBeforeChanges; }