예제 #1
0
        private void RouteStopAdded(RouteDetails routeDetails, RouteStopAdded @event)
        {
            var stopDetails = new RouteStopDetails
            {
                StopId   = @event.RouteId,
                Name     = @event.Name.Value,
                Position = new Position(@event.Position.Latitude, @event.Position.Longitude)
            };

            routeDetails.Stops.Add(stopDetails);
            routeDetails.StopsArea = CalculateArea(routeDetails);
        }
예제 #2
0
 public void Apply(RouteStopAdded @event)
 {
     _stops.Add(new Stop(@event.Name, @event.TimeOfDay, @event.Position));
 }