public ThermostatViewModel(Thermostat thermostat) { if (DesignerProperties.IsInDesignTool) { return; } _thermostat = thermostat; _statusProvider = ServiceContainer.GetService <IStatusProvider>(); _nestWebService = ServiceContainer.GetService <INestWebService>(); _statusUpdater = ServiceContainer.GetService <IStatusUpdaterService>(); _exceptionHandler = ServiceContainer.GetService <IExceptionHandler>(); _statusProvider.StatusUpdated += OnStatusUpdated; }
public NestViewModel() { if (DesignerProperties.IsInDesignTool) { return; } _statusProvider = ServiceContainer.GetService <IStatusProvider>(); _sessionProvider = ServiceContainer.GetService <ISessionProvider>(); _nestWebService = ServiceContainer.GetService <INestWebService>(); _statusUpdater = ServiceContainer.GetService <IStatusUpdaterService>(); _analyticsService = ServiceContainer.GetService <IAnalyticsService>(); _statusProvider.StatusUpdated += OnStatusUpdated; }
public NestViewModel() { if (DesignerProperties.IsInDesignTool) return; _statusProvider = ServiceContainer.GetService<IStatusProvider>(); _sessionProvider = ServiceContainer.GetService<ISessionProvider>(); _nestWebService = ServiceContainer.GetService<INestWebService>(); _statusUpdater = ServiceContainer.GetService<IStatusUpdaterService>(); _analyticsService = ServiceContainer.GetService<IAnalyticsService>(); _statusProvider.StatusUpdated += OnStatusUpdated; }