コード例 #1
0
 public Leg(LegDto leg)
 {
     DepartureTime = leg.DepartureTime;
     ArrivalTime   = leg.ArrivalTime;
     Duration      = TimeSpan.FromTicks(leg.Duration);
     SummaryHtml   = leg.SummaryHtml;
     Stops         = leg.ScheduledStopCalls?.Count ?? 0;
     Polyline      = leg.Polyline;
     VehicleType   = leg.VehicleType;
 }
コード例 #2
0
 protected bool Equals(LegDto other)
 {
     return(string.Equals(From, other.From) && string.Equals(To, other.To) && Distance == other.Distance && Cost == other.Cost && Type == other.Type);
 }