Exemplo n.º 1
0
 public RunnerService(
     ILoggerFactory loggerFactory,
     IOptions <NetDaemonSettings> netDaemonSettings,
     IOptions <HomeAssistantSettings> homeAssistantSettings,
     IServiceProvider serviceProvider,
     IYamlConfig yamlConfig,
     IDaemonAppCompiler daemonAppCompiler
     )
 {
     _logger = loggerFactory.CreateLogger <RunnerService>();
     _homeAssistantSettings = homeAssistantSettings.Value;
     _netDaemonSettings     = netDaemonSettings.Value;
     _serviceProvider       = serviceProvider;
     _yamlConfig            = yamlConfig;
     _daemonAppCompiler     = daemonAppCompiler;
 }
Exemplo n.º 2
0
 public RunnerService(
     ILoggerFactory loggerFactory,
     IOptions <NetDaemonSettings> netDaemonSettings,
     IOptions <HomeAssistantSettings> homeAssistantSettings,
     IServiceProvider serviceProvider,
     IYamlConfig yamlConfig,
     IDaemonAppCompiler daemonAppCompiler
     )
 {
     _ = homeAssistantSettings ??
         throw new NetDaemonArgumentNullException(nameof(homeAssistantSettings));
     _ = netDaemonSettings ??
         throw new NetDaemonArgumentNullException(nameof(netDaemonSettings));
     _logger = loggerFactory.CreateLogger <RunnerService>();
     _homeAssistantSettings = homeAssistantSettings.Value;
     _netDaemonSettings     = netDaemonSettings.Value;
     _serviceProvider       = serviceProvider;
     _yamlConfig            = yamlConfig;
     _daemonAppCompiler     = daemonAppCompiler;
 }