private static async Task <IList <Station> > FetchStationsFromServer() { RnvRequest request = new RnvRequest(); IList <Station> stations = await request.FetchStations(); return(stations); }
private async Task ShowDepartures(string hafasId) { RnvRequest request = new RnvRequest(); Journey journey = await request.FetchDeparturesForStation(hafasId); // Since data is fetched asynchronously, ReloadData() must be called after assigning the view source. // Otherwise, it's not going to be displayed. this.DepartureListTableView.Source = new DepartureListTableViewSource(journey.ListOfDepartures); this.DepartureListTableView.ReloadData(); }
static RnvRequest() { RnvRequest.InitializeClient(); }