示例#1
0
 public void AddSubRoute(SubRoute subRoute)
 {
     RouteSubRoutes.Add(subRoute);
     SetMiddleCity();
     Cost = RouteSubRoutes.Sum(x => x.Cost);
     Time = RouteSubRoutes.Sum(x => x.Time);
 }
示例#2
0
        public List <Stop> GetStops()
        {
            var stops = RouteSubRoutes.Select(x => x.From).ToList();

            stops.Add(Destination);
            return(stops);
        }