Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Component = &component.Component{ Dependencies: component.Components{ runner.Component, restore.ComponentNoRegistration, config.Component, }, Init: component.StepFunc(func(container container.Container) error { return container.Provides( newRepeater, func(r *repeater) Repeater { return r }, ) }), Execute: component.StepFunc(func(container container.Container) error { return container.Invoke(func(r runner.Runner, restore *restore.Restore, repeater Repeater) error { return r.RunProcess(runner.NewTask(repeater.Name(), repeater.Process, restore)) }) }), Stop: component.StepFunc(func(container container.Container) error { return container.Invoke(func(repeater Repeater) error { return repeater.Close() }) }), } ComponentNoRestore = &component.Component{ Dependencies: component.Components{ runner.Component, config.Component, }, Init: component.StepFunc(func(container container.Container) error { return container.Provides( newRepeater, func(r *repeater) Repeater { return r }, ) }), Execute: component.StepFunc(func(container container.Container) error { return container.Invoke(func(r runner.Runner, repeater Repeater) error { return r.RunProcess(repeater) }) }), Stop: component.StepFunc(func(container container.Container) error { return container.Invoke(func(repeater Repeater) error { return repeater.Close() }) }), } )
Functions ¶
This section is empty.
Types ¶
type Task ¶
type Task struct {
// contains filtered or unexported fields
}
func NewTask ¶
func NewTask(name string, delay time.Duration, processFunc runner.ProcessFunc, middlewares ...runner.Middleware) *Task
func (*Task) RunNumbers ¶
Click to show internal directories.
Click to hide internal directories.