Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BaseTask ¶
type BaseTask[E any] struct { // contains filtered or unexported fields }
func (*BaseTask[E]) Status ¶
func (t *BaseTask[E]) Status() TaskStatus
type Task ¶
type Task[E any] interface { Status() TaskStatus Control() bt.Optional[Task[E]] SetControl(c bt.Optional[Task[E]]) Guard() bt.Optional[Task[E]] SetGuard(g bt.Optional[Task[E]]) AddChild(child Task[E]) int NumChildren() int GetChild(idx int) Task[E] Object() E CheckGuard(control Task[E]) bool Start() End() Run() Running() Success() Fail() ChildRunning(task, reporter Task[E]) ChildSuccess(task Task[E]) ChildFail(task Task[E]) Cancel() CancelRunningChildren(startIdx int) }
type TaskStatus ¶
type TaskStatus int8
const ( TaskFresh TaskStatus = iota TaskRunning TaskFailed TaskSucceeded TaskCancelled )
Click to show internal directories.
Click to hide internal directories.