public WindowsServiceManager(IWindowsServiceProviderFactory providerFactory, IRegistryEditor registryEditor, IFileManager fileManager, IConfigurationReader configurationReader) { _providerFactory = providerFactory ?? throw new ArgumentNullException(nameof(providerFactory)); _registryEditor = registryEditor ?? throw new ArgumentNullException(nameof(registryEditor)); _fileManager = fileManager ?? throw new ArgumentNullException(nameof(fileManager)); _configurationReader = configurationReader ?? throw new ArgumentNullException(nameof(configurationReader)); }
public WindowsServiceManager(IWindowsServiceProviderFactory providerFactory, IRegistryEditor registryEditor, IFileManager fileManager, string[] windowsServices) { _providerFactory = providerFactory ?? throw new ArgumentNullException(nameof(providerFactory)); _registryEditor = registryEditor ?? throw new ArgumentNullException(nameof(registryEditor)); _fileManager = fileManager ?? throw new ArgumentNullException(nameof(fileManager)); _windowsServices = windowsServices ?? new string[0]; }
public WindowsServiceManager(IWindowsServiceProviderFactory providerFactory, IFilesHelper filesHelper, IWindowsServices serviceNames) { _providerFactory = providerFactory ?? throw new ArgumentNullException(nameof(providerFactory)); _filesHelper = filesHelper ?? throw new ArgumentNullException(nameof(filesHelper)); _serviceNames = serviceNames ?? throw new ArgumentNullException(nameof(serviceNames)); if (!_serviceNames.Any()) { throw new ArgumentNullException(nameof(serviceNames)); } }