Beispiel #1
0
        public bool Equals(TripTime other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }

            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return(other.Index == Index);
        }
Beispiel #2
0
        public static void InitializeTripTimes()
        {
            if (Times != null)
            {
                return;
            }

            Times = new TripTime[TOTAL_TRIP_TIMES];

            var alternativeIndex = 0;

            foreach (var minuteSpan in DayPeriod.SmallDayPeriods)
            {
                var time = new TripTime(alternativeIndex, minuteSpan);

                Times[alternativeIndex++] = time;
            }
        }