예제 #1
0
 internal void Apply(CarHasTraveledADistance @event)
 {
     TraveledDistance = TraveledDistance.Add(Distance.FromKilometers(@event.DistanceInKilometers));
 }
예제 #2
0
 internal void Apply(CarCreated @event)
 {
     Id = @event.Id;
     TraveledDistance = Distance.Empty();
 }