public PresentationService()
 {
     var applicationRootPath = System.Web.Hosting.HostingEnvironment.MapPath("/");
     var keyPath = System.Web.Hosting.HostingEnvironment.MapPath("/env/openWeatherMapKey.txt");
     _settingsService = new SettingsService(applicationRootPath, keyPath);
     context = HttpContext.Current;
     Weather = new PresentationWeather(context, _settingsService);
 }
Exemple #2
0
 public BaseService(SettingsService settingsService)
 {
     SettingsService = settingsService;
     Settings = new Settings { KeyPath = settingsService.GetKeyPath(), };
 }
 public WeatherService(SettingsService settingsService) : base(settingsService)
 {
 }
Exemple #4
0
 public BaseService(SettingsService settingsService)
 {
     SettingsService = settingsService;
     Settings        = new Settings(settingsService.GetKeyPath(), settingsService.GetConfigurationPath());
 }
 public PresentationWeather(HttpContext context, SettingsService settingsService)
 {
     this.context = context;
     _weatherService = new WeatherService(settingsService);
 }