C# Класс Topshelf.Runtime.Windows.WindowsHostEnvironment

Наследование: HostEnvironment
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
CreateServiceHost ( HostSettings settings, ServiceHandle serviceHandle ) : Host
InstallService ( InstallHostSettings settings, Action beforeInstall, System.Action afterInstall, System.Action beforeRollback, System.Action afterRollback ) : void
IsServiceInstalled ( string serviceName ) : bool
IsServiceStopped ( string serviceName ) : bool
RunAsAdministrator ( ) : bool
SendServiceCommand ( string serviceName, int command ) : void
StartService ( string serviceName, System.TimeSpan startTimeOut ) : void
StopService ( string serviceName, System.TimeSpan stopTimeOut ) : void
UninstallService ( HostSettings settings, System.Action beforeUninstall, System.Action afterUninstall ) : void
WindowsHostEnvironment ( HostConfigurator configurator ) : System

Приватные методы

Метод Описание
GetParent ( Process child ) : Process
IsServiceListed ( string serviceName ) : bool

Описание методов

CreateServiceHost() публичный Метод

public CreateServiceHost ( HostSettings settings, ServiceHandle serviceHandle ) : Host
settings HostSettings
serviceHandle ServiceHandle
Результат Host

InstallService() публичный Метод

public InstallService ( InstallHostSettings settings, Action beforeInstall, System.Action afterInstall, System.Action beforeRollback, System.Action afterRollback ) : void
settings InstallHostSettings
beforeInstall Action
afterInstall System.Action
beforeRollback System.Action
afterRollback System.Action
Результат void

IsServiceInstalled() публичный Метод

public IsServiceInstalled ( string serviceName ) : bool
serviceName string
Результат bool

IsServiceStopped() публичный Метод

public IsServiceStopped ( string serviceName ) : bool
serviceName string
Результат bool

RunAsAdministrator() публичный Метод

public RunAsAdministrator ( ) : bool
Результат bool

SendServiceCommand() публичный Метод

public SendServiceCommand ( string serviceName, int command ) : void
serviceName string
command int
Результат void

StartService() публичный Метод

public StartService ( string serviceName, System.TimeSpan startTimeOut ) : void
serviceName string
startTimeOut System.TimeSpan
Результат void

StopService() публичный Метод

public StopService ( string serviceName, System.TimeSpan stopTimeOut ) : void
serviceName string
stopTimeOut System.TimeSpan
Результат void

UninstallService() публичный Метод

public UninstallService ( HostSettings settings, System.Action beforeUninstall, System.Action afterUninstall ) : void
settings HostSettings
beforeUninstall System.Action
afterUninstall System.Action
Результат void

WindowsHostEnvironment() публичный Метод

public WindowsHostEnvironment ( HostConfigurator configurator ) : System
configurator HostConfigurator
Результат System