Documentation ¶
Rendered for windows/amd64
Index ¶
- type WinService
- func (winService WinService) ControlService(name string, c svc.Cmd, to svc.State) error
- func (winService *WinService) Execute(args []string, r <-chan svc.ChangeRequest, changes chan<- svc.Status) (ssec bool, errno uint32)
- func (winService WinService) InstallService(name, displayName string, description string) error
- func (winService WinService) InstallServiceWithOptions(name string, config mgr.Config, recoveryActions []mgr.RecoveryAction, ...) error
- func (winService WinService) RemoveService(name string) error
- func (winService WinService) RunService(name string, isDebug bool)
- func (winService WinService) StartService(name string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type WinService ¶
type WinService struct { UseEventLog bool // Does the Windows service want events recorded to the application event log? Start func() // Pointer to function that framework will call to start the service Stop func() // Pointer to function that framework will call to stop the service }
WinService is a structure that the Windows client service must initialize prior to calling our winservice member functions.
func (WinService) ControlService ¶
ControlService is called to control the Windows service
func (*WinService) Execute ¶
func (winService *WinService) Execute(args []string, r <-chan svc.ChangeRequest, changes chan<- svc.Status) (ssec bool, errno uint32)
Execute is the thread executing the service and receiving control events
func (WinService) InstallService ¶
func (winService WinService) InstallService(name, displayName string, description string) error
InstallService is used to install the service
func (WinService) InstallServiceWithOptions ¶
func (winService WinService) InstallServiceWithOptions(name string, config mgr.Config, recoveryActions []mgr.RecoveryAction, resetPeriod uint32) error
InstallServiceWithOptions is used to install the service with the provided configuration and recovery options.
func (WinService) RemoveService ¶
func (winService WinService) RemoveService(name string) error
RemoveService is used to uninstall the service
func (WinService) RunService ¶
func (winService WinService) RunService(name string, isDebug bool)
RunService is called to run the Windows service
func (WinService) StartService ¶
func (winService WinService) StartService(name string) error
StartService is called to start the Windows service
Click to show internal directories.
Click to hide internal directories.