Created
June 6, 2014 13:02
-
-
Save DominicFinn/49c3a4cb96b29c9a9bb8 to your computer and use it in GitHub Desktop.
Example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Appointment : IAggregateRoot | |
{ | |
public Appointment(Guid id, AppointmentType type, .....) | |
{ | |
switch type | |
{ | |
case: AppointmentType.TypeOne | |
Apply(new TypeOneAppointmentCreated()); | |
case: AppointmentType.TypeTwo | |
Apply(new TypeTwoAppointmentCreated()); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment