1
0
Fork 0
hivemind/internal/roles/role.go

21 lines
420 B
Go

package roles
import (
"context"
"git.wzray.com/homelab/hivemind/internal/transport"
)
type Role interface {
RegisterHandlers(transport.Registrator)
OnStartup(context.Context) error
OnShutdown() error
}
type BaseRole struct{}
func (r *BaseRole) RegisterHandlers(transport.Registrator) {}
func (r *BaseRole) OnStartup(context.Context) error { return nil }
func (r *BaseRole) OnShutdown() error { return nil }