public static IAirTravelManager Create(string manager) { IAirTravelManager airtravelManager = null; switch (manager) { case "Airline": airtravelManager = new AirLineManager(); break; case "City": airtravelManager = new CityManager(); break; case "Flight": airtravelManager = new FlightManager(); break; case "Route": airtravelManager = new RouteManager(); break; case "Schedule": airtravelManager = new ScheduleManager(); break; } return(airtravelManager); }
public List <HappyTrip.Model.Entities.AirTravel.Airline> GetAllAirlinesCollecction() { AirLineManager am = new AirLineManager(); AllAirlines = new List <Entities.AirTravel.Airline>(); AllAirlines = am.GetAirLines().ToList(); AllAirlines.Sort(); return(AllAirlines); }