Documentation ¶
Index ¶
- Constants
- func DefaultControllerBuilder[T work_schedule.Work](app app_context.Context, workBuilder work_schedule.WorkBuilder[T], ...) (work_schedule.WorkScheduler[T], error)
- func PostWork[T work_schedule.Work]() console_tool.Handler[*WorkScheduleCommands[T]]
- type HandlerBase
- type PostWorkData
- type PostWorkHandler
- type WorkScheduleCommands
- type WorkSchedulerBuilder
Constants ¶
View Source
const PostWorkCmd string = "post-work"
View Source
const PostWorkDescription string = "Post work"
Variables ¶
This section is empty.
Functions ¶
func DefaultControllerBuilder ¶
func DefaultControllerBuilder[T work_schedule.Work](app app_context.Context, workBuilder work_schedule.WorkBuilder[T], shedulerName string, pubsubTopicName string, configPath string) (work_schedule.WorkScheduler[T], error)
func PostWork ¶
func PostWork[T work_schedule.Work]() console_tool.Handler[*WorkScheduleCommands[T]]
Types ¶
type HandlerBase ¶
type HandlerBase[T work_schedule.Work] struct { console_tool.HandlerBase[*WorkScheduleCommands[T]] }
func (*HandlerBase[T]) Context ¶
func (b *HandlerBase[T]) Context(data interface{}) (multitenancy.TenancyContext, work_schedule.WorkScheduler[T], error)
type PostWorkData ¶
type PostWorkData struct { ReferenceType string `long:"reference_type" description:"Work reference type" validate:"required" vmessage:"Invalid reference type"` ReferenceId string `long:"reference_id" description:"Work reference ID" validate:"required,id" vmessage:"Invalid reference ID"` Mode string `` /* 130-byte string literal not displayed */ Delay int `long:"delay" description:"Work invokation delay"` }
type PostWorkHandler ¶
type PostWorkHandler[T work_schedule.Work] struct { HandlerBase[T] PostWorkData }
func (*PostWorkHandler[T]) Data ¶
func (a *PostWorkHandler[T]) Data() interface{}
func (*PostWorkHandler[T]) Execute ¶
func (a *PostWorkHandler[T]) Execute(args []string) error
type WorkScheduleCommands ¶
type WorkScheduleCommands[T work_schedule.Work] struct { console_tool.Commands[*WorkScheduleCommands[T]] MakeController WorkSchedulerBuilder[T] }
func NewWorkScheduleCommands ¶
func NewWorkScheduleCommands[T work_schedule.Work](name string, description string, makeController WorkSchedulerBuilder[T]) *WorkScheduleCommands[T]
func (*WorkScheduleCommands[T]) LoadHandlers ¶
func (w *WorkScheduleCommands[T]) LoadHandlers()
type WorkSchedulerBuilder ¶
type WorkSchedulerBuilder[T work_schedule.Work] func(app app_context.Context) (work_schedule.WorkScheduler[T], error)
func MakeDefaultControllerBuilder ¶
func MakeDefaultControllerBuilder[T work_schedule.Work](workBuilder work_schedule.WorkBuilder[T], shedulerName string, pubsubTopicName string, configPath string) WorkSchedulerBuilder[T]
Click to show internal directories.
Click to hide internal directories.