Documentation ¶
Index ¶
- type Service
- func (svr *Service) Execute(args []string) (err error)
- func (svr *Service) IsConsole() bool
- func (svr *Service) IsService() bool
- func (svr *Service) ServiceDescription() string
- func (svr *Service) ServiceDisplayName() string
- func (svr *Service) ServiceExeFolder() string
- func (svr *Service) ServiceExeName() string
- func (svr *Service) ServiceName() string
- func (svr *Service) Start(s service.Service) error
- func (svr *Service) Stop(s service.Service) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service struct
func NewService ¶
func NewService(name string, displayName string, description string, start func(*Service, ...string), run func(*Service, ...string), stop func(*Service, ...string)) (svr *Service, err error)
NewService invoke new *Service name - ServiceName displayName - ServiceDisplayName description - ServiceDescription start - func(*Service, ...string) implementation, gets invoked when Service Start run - func(*Service, ...string) implementation, gets invoked when Service Run stop - func(*Service, ...string) implementation, gets invoked when Service Stop
func (*Service) Execute ¶
Execute main Service Execute method when executing Service called in main() func of golang app, args - args from os gets passed into here
func (*Service) ServiceDescription ¶
ServiceDescription Service Description
func (*Service) ServiceDisplayName ¶
ServiceDisplayName Service Display Name
func (*Service) ServiceExeFolder ¶
ServiceExeFolder local folder where Service Executable resides
func (*Service) ServiceExeName ¶
ServiceExeName Service Executable Name