Freigeben über


WindowsServiceLifetime Konstruktoren

Definition

Überlädt

WindowsServiceLifetime(IHostEnvironment, IHostApplicationLifetime, ILoggerFactory, IOptions<HostOptions>)

Initialisiert eine neue WindowsServiceLifetime Instanz.

WindowsServiceLifetime(IHostEnvironment, IHostApplicationLifetime, ILoggerFactory, IOptions<HostOptions>, IOptions<WindowsServiceLifetimeOptions>)

Initialisiert eine neue Instanz der WindowsServiceLifetime Klasse.

WindowsServiceLifetime(IHostEnvironment, IHostApplicationLifetime, ILoggerFactory, IOptions<HostOptions>)

Quelle:
WindowsServiceLifetime.cs
Quelle:
WindowsServiceLifetime.cs
Quelle:
WindowsServiceLifetime.cs

Initialisiert eine neue WindowsServiceLifetime Instanz.

public:
 WindowsServiceLifetime(Microsoft::Extensions::Hosting::IHostEnvironment ^ environment, Microsoft::Extensions::Hosting::IHostApplicationLifetime ^ applicationLifetime, Microsoft::Extensions::Logging::ILoggerFactory ^ loggerFactory, Microsoft::Extensions::Options::IOptions<Microsoft::Extensions::Hosting::HostOptions ^> ^ optionsAccessor);
public WindowsServiceLifetime (Microsoft.Extensions.Hosting.IHostEnvironment environment, Microsoft.Extensions.Hosting.IHostApplicationLifetime applicationLifetime, Microsoft.Extensions.Logging.ILoggerFactory loggerFactory, Microsoft.Extensions.Options.IOptions<Microsoft.Extensions.Hosting.HostOptions> optionsAccessor);
new Microsoft.Extensions.Hosting.WindowsServices.WindowsServiceLifetime : Microsoft.Extensions.Hosting.IHostEnvironment * Microsoft.Extensions.Hosting.IHostApplicationLifetime * Microsoft.Extensions.Logging.ILoggerFactory * Microsoft.Extensions.Options.IOptions<Microsoft.Extensions.Hosting.HostOptions> -> Microsoft.Extensions.Hosting.WindowsServices.WindowsServiceLifetime
Public Sub New (environment As IHostEnvironment, applicationLifetime As IHostApplicationLifetime, loggerFactory As ILoggerFactory, optionsAccessor As IOptions(Of HostOptions))

Parameter

environment
IHostEnvironment

Informationen zum Host.

applicationLifetime
IHostApplicationLifetime

Die IHostApplicationLifetime, die die Dienstlebensdauer nachverfolgt.

loggerFactory
ILoggerFactory

Die ILoggerFactory verwendet, um den Lebensdauerprotokollierer zu instanziieren.

optionsAccessor
IOptions<HostOptions>

Die IOptions<TOptions>, die Optionen für den Dienst enthält.

Gilt für:

WindowsServiceLifetime(IHostEnvironment, IHostApplicationLifetime, ILoggerFactory, IOptions<HostOptions>, IOptions<WindowsServiceLifetimeOptions>)

Quelle:
WindowsServiceLifetime.cs
Quelle:
WindowsServiceLifetime.cs
Quelle:
WindowsServiceLifetime.cs

Initialisiert eine neue Instanz der WindowsServiceLifetime Klasse.

public:
 WindowsServiceLifetime(Microsoft::Extensions::Hosting::IHostEnvironment ^ environment, Microsoft::Extensions::Hosting::IHostApplicationLifetime ^ applicationLifetime, Microsoft::Extensions::Logging::ILoggerFactory ^ loggerFactory, Microsoft::Extensions::Options::IOptions<Microsoft::Extensions::Hosting::HostOptions ^> ^ optionsAccessor, Microsoft::Extensions::Options::IOptions<Microsoft::Extensions::Hosting::WindowsServiceLifetimeOptions ^> ^ windowsServiceOptionsAccessor);
public WindowsServiceLifetime (Microsoft.Extensions.Hosting.IHostEnvironment environment, Microsoft.Extensions.Hosting.IHostApplicationLifetime applicationLifetime, Microsoft.Extensions.Logging.ILoggerFactory loggerFactory, Microsoft.Extensions.Options.IOptions<Microsoft.Extensions.Hosting.HostOptions> optionsAccessor, Microsoft.Extensions.Options.IOptions<Microsoft.Extensions.Hosting.WindowsServiceLifetimeOptions> windowsServiceOptionsAccessor);
new Microsoft.Extensions.Hosting.WindowsServices.WindowsServiceLifetime : Microsoft.Extensions.Hosting.IHostEnvironment * Microsoft.Extensions.Hosting.IHostApplicationLifetime * Microsoft.Extensions.Logging.ILoggerFactory * Microsoft.Extensions.Options.IOptions<Microsoft.Extensions.Hosting.HostOptions> * Microsoft.Extensions.Options.IOptions<Microsoft.Extensions.Hosting.WindowsServiceLifetimeOptions> -> Microsoft.Extensions.Hosting.WindowsServices.WindowsServiceLifetime
Public Sub New (environment As IHostEnvironment, applicationLifetime As IHostApplicationLifetime, loggerFactory As ILoggerFactory, optionsAccessor As IOptions(Of HostOptions), windowsServiceOptionsAccessor As IOptions(Of WindowsServiceLifetimeOptions))

Parameter

environment
IHostEnvironment

Informationen zum Host.

applicationLifetime
IHostApplicationLifetime

Die IHostApplicationLifetime, die die Dienstlebensdauer nachverfolgt.

loggerFactory
ILoggerFactory

Die ILoggerFactory verwendet, um den Lebensdauerprotokollierer zu instanziieren.

optionsAccessor
IOptions<HostOptions>

Die IOptions<TOptions>, die Optionen für den Dienst enthält.

windowsServiceOptionsAccessor
IOptions<WindowsServiceLifetimeOptions>

Die Windows-Dienstoptionen, die zum Suchen des Dienstnamens verwendet werden.

Gilt für: