Exemplo n.º 1
0
 public NetatmoWeatherPollingService(ILogger <NetatmoWeatherPollingService> logger, INetatmoDbContext databaseContext, NetatmoWebClient netatmoClient, INetatmoDeviceService netatmoStructure)
 {
     _logger           = logger;
     _dbContext        = databaseContext;
     _netatmoClient    = netatmoClient;
     _netatmoStructure = netatmoStructure;
 }
Exemplo n.º 2
0
 public NetatmoMeasureViewModel(INetatmoDbContext databaseContext, INetatmoDeviceService netatmoStructure)
     : base(new Dictionary <Resolution, IQueryable <NetatmoMeasureData> >() {
     { Resolution.LowRes, databaseContext.NetatmoMeasureLowresDataSet },
     { Resolution.MidRes, databaseContext.NetatmoMeasureDataSet }
 },
            Enumerable.Range(0, 1).ToDictionary(x => x.ToString(), x => x),
            netatmoStructure.Modules.SelectMany(x => netatmoStructure.GetModuleMeasures(x.Item2)
                                                .Select(m => netatmoStructure.GetModuleMeasureDbId(x.Item2, m))
                                                )
            .Where(x => x != null && x.HasValue).Select(x => x !.Value)
Exemplo n.º 3
0
 public NetatmoController(INetatmoDbContext databaseContext, INetatmoDeviceService netatmoStructure)
 {
     _databaseContext  = databaseContext;
     _netatmoStructure = netatmoStructure;
 }