Documentation ¶
Index ¶
- type BasicController
- func (c BasicController) CreateService(service model.Service) error
- func (c BasicController) DeleteService(key string) error
- func (c BasicController) GetService(key string) (model.Service, error)
- func (c BasicController) GetServices() ([]model.Service, error)
- func (c BasicController) UpsertService(service model.Service) error
- type Controller
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BasicController ¶
type BasicController struct {
// contains filtered or unexported fields
}
func (BasicController) CreateService ¶ added in v0.0.11
func (c BasicController) CreateService(service model.Service) error
CreateService creates a new service
func (BasicController) DeleteService ¶
func (c BasicController) DeleteService(key string) error
DeleteService deletes a service
func (BasicController) GetService ¶
func (c BasicController) GetService(key string) (model.Service, error)
GetService gets a service
func (BasicController) GetServices ¶
func (c BasicController) GetServices() ([]model.Service, error)
GetServices gets services paginated
func (BasicController) UpsertService ¶ added in v0.0.11
func (c BasicController) UpsertService(service model.Service) error
UpdateServiceStatus updates the status of a service
type Controller ¶
type Controller interface { CreateService(service model.Service) error GetServices() ([]model.Service, error) GetService(key string) (model.Service, error) DeleteService(key string) error UpsertService(service model.Service) error }
func NewController ¶
func NewController( serviceRepo repository.ServiceRepo, logger log.Logger, ) Controller
Click to show internal directories.
Click to hide internal directories.