app/task/service.go

24 lines
521 B
Go
Raw Permalink Normal View History

2021-12-16 04:11:33 +00:00
package task
type Service struct{}
func (srv Service) GetName() string { return "task.Service" }
func (srv Service) GetDependencies() []string { return []string{} }
func (srv Service) IsService() bool { return true }
func (srv Service) Init() error {
Init()
return nil
}
func (srv Service) Load() error { return nil }
func (srv Service) Main() error {
Start()
return nil
}
func (srv Service) Del() {
if c == nil {
return
}
<-Stop().Done()
}
func (srv Service) Health() error { return nil }