public IEnumerable <Airport> GetAirports() { IEnumerable <Airport> airports = null; using (var stream = fileHelper.ReadResourceFileAsStream("GuestlogixTestXF.Data.airports.csv")) { airports = CsvConverter.Serialize <Airport>(stream); } return(airports); }
/// <summary> /// Returns all routes from the CSV-file /// </summary> public IEnumerable <Route> GetRoutes() { IEnumerable <Route> routes = null; using (var stream = fileHelper.ReadResourceFileAsStream("GuestlogixTestXF.Data.routes.csv")) { routes = CsvConverter.Serialize <Route>(stream); } return(routes); }