goplatform

package
v0.0.0-...-91ccd0e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 13, 2019 License: MIT Imports: 3 Imported by: 0

Documentation

Index

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

func (svr *Service) Execute(args []string) (err error)

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) IsConsole

func (svr *Service) IsConsole() bool

IsConsole Service

func (*Service) IsService

func (svr *Service) IsService() bool

IsService Service

func (*Service) ServiceDescription

func (svr *Service) ServiceDescription() string

ServiceDescription Service Description

func (*Service) ServiceDisplayName

func (svr *Service) ServiceDisplayName() string

ServiceDisplayName Service Display Name

func (*Service) ServiceExeFolder

func (svr *Service) ServiceExeFolder() string

ServiceExeFolder local folder where Service Executable resides

func (*Service) ServiceExeName

func (svr *Service) ServiceExeName() string

ServiceExeName Service Executable Name

func (*Service) ServiceName

func (svr *Service) ServiceName() string

ServiceName Service Name

func (*Service) Start

func (svr *Service) Start(s service.Service) error

Start Service

func (*Service) Stop

func (svr *Service) Stop(s service.Service) error

Stop Service

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL