public App(IAssetLoader assetLoader) { var dataProvider = new DataProvider(assetLoader); var cityProvider = new CityProvider(assetLoader); ServiceProvider.Register <IAssetLoader>(assetLoader); ServiceProvider.Register <DataProvider>(dataProvider); ServiceProvider.Register <CityProvider>(cityProvider); InitializeComponent(); MainPage = new MainPage(); }
private static void GetListCitiesByFirstChar() { logger.ShowLine("Please enter the first letters of the city:"); var firstLetters = System.Console.ReadLine(); var cities = new CityProvider(); var sortedCities = cities.GetListCitiesByFirstLetters(firstLetters); foreach (CityConfig city in sortedCities) { logger.Show($"{city.Name}; "); } }
public void ExecuteTest() { CityValidateEntity AddressValidationRequest = new CityValidateEntity() { Address = new CityAddressEntity() { StateProvinceCode = "", City = "", PostalCode = "43202" } }; CityProvider provider = new CityProvider(); provider.AddressValidationRequest = AddressValidationRequest; List <AVRResultEntity> result = provider.Execute(); Console.WriteLine(JsonHelper.SerializeObject(result)); Assert.Fail(); }