Beispiel #1
0
 private void When(SchoolCreatedDomainEvent domainEvent)
 {
     Id      = domainEvent.AggregateRootId;
     name    = domainEvent.SchoolName;
     manager = Teacher.Create(domainEvent.ManagerId, domainEvent.ManagerName);
 }
Beispiel #2
0
 public void CreateWithManager(Teacher teacher)
 {
     Raise(SchoolCreatedDomainEvent.Create(
               this, this.name, teacher.Id, teacher.GetName()));
 }