Пример #1
0
 public void AddRange(FlightCollection itemCollection)
 {
     foreach (Flight item in itemCollection)
     {
         items.Add(item);
     }
 }
Пример #2
0
 public Race()
     : base()
 {
     competitors = new CompetitorCollection();
     competitorGroups = new CompetitorGroupCollection();
     flights = new FlightCollection();
     date = new DateTime();
     map = new Map();
     takeOffGate = new Gate();
     defaultRunway = true;
     defaultTargetFlightDuration = new TimeSpan(0);
     timeToStartGateDefault = new TimeSpan(0);
     timeToStartGateAlternative = new TimeSpan(0);
 }
Пример #3
0
 public FlightCollection GetFlightsByGroupId(Guid groupId)
 {
     FlightCollection flightsForCurrentGroup = new FlightCollection();
     foreach (Flight flight in items)
     {
         if (flight.CompetitorGroupId == groupId)
         {
             flightsForCurrentGroup.Add(flight);
         }
     }
     return flightsForCurrentGroup;
 }
Пример #4
0
 public FlightCollection GetFlightsByCompetitorId(Guid competitorId)
 {
     FlightCollection flightsForCurrentCompetitor = new FlightCollection();
     foreach (Flight flight in items)
     {
         if (flight.CompetitorId == competitorId)
         {
             flightsForCurrentCompetitor.Add(flight);
         }
     }
     return flightsForCurrentCompetitor;
 }