Documentation ¶
Overview ¶
Package task is a generated protocol buffer package.
It is generated from these files:
github.com/GoCollaborate/src/artifacts/task/task.proto
It has these top-level messages:
TaskPayload
Index ¶
- Constants
- type Background
- type Collection
- type Job
- func (j *Job) Back() *Stage
- func (j *Job) Curr() *Stage
- func (j *Job) Exes(i int) ([]string, error)
- func (j *Job) Front() *Stage
- func (j *Job) Id() string
- func (j *Job) Init(s *Stage) *Stage
- func (j *Job) InsertAfter(aft *Stage, curr *Stage) *Stage
- func (j *Job) InsertBefore(bef *Stage, curr *Stage) *Stage
- func (j *Job) Len() int
- func (j *Job) PushBack(back *Stage) *Stage
- func (j *Job) PushFront(front *Stage) *Stage
- func (j *Job) Stacks(stacks ...string) *Job
- func (j *Job) Tasks(tsks ...*Task)
- type Stage
- type Task
- type TaskContext
- type TaskFuture
- type TaskPayload
- type TaskPriority
- type TaskType
Constants ¶
View Source
const ( SHORT taskType = iota LONG ROUTINE PERMANENT )
View Source
const ( BASE taskPriority = iota LOW MEDIUM HIGH URGENT )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Background ¶
type Background chan *Job
func NewBackground ¶
func NewBackground() *Background
func (*Background) Close ¶
func (bg *Background) Close()
func (*Background) Done ¶
func (bg *Background) Done() *Job
func (*Background) Mount ¶
func (bg *Background) Mount(job *Job)
type Collection ¶
type Collection []interface{}
func NewCollection ¶
func NewCollection() *Collection
func (*Collection) Append ¶
func (cg *Collection) Append(cs ...interface{}) *Collection
func (*Collection) Filter ¶
func (cg *Collection) Filter(f func(interface{}) bool) *Collection
func (*Collection) IsEmpty ¶
func (cg *Collection) IsEmpty() bool
func (*Collection) Length ¶
func (cg *Collection) Length() int
type Task ¶
type Task struct { Type taskType Priority taskPriority Consumable string Source Collection Result Collection Context *TaskContext Stage int }
type TaskContext ¶
type TaskContext struct {
Context map[string]interface{}
}
func NewTaskContext ¶
func NewTaskContext(ctx interface{}) *TaskContext
func (*TaskContext) Entries ¶
func (this *TaskContext) Entries() map[string]interface{}
func (*TaskContext) Get ¶
func (this *TaskContext) Get(key string) (interface{}, error)
func (*TaskContext) Set ¶
func (this *TaskContext) Set(key string, val interface{})
type TaskFuture ¶
type TaskFuture struct {
// contains filtered or unexported fields
}
func NewTaskFuture ¶
func NewTaskFuture(in *Task) *TaskFuture
func (*TaskFuture) Close ¶
func (tf *TaskFuture) Close()
func (*TaskFuture) Done ¶
func (tf *TaskFuture) Done() bool
func (*TaskFuture) Error ¶
func (tf *TaskFuture) Error() error
func (*TaskFuture) IsDone ¶
func (tf *TaskFuture) IsDone() chan bool
func (*TaskFuture) Receive ¶
func (tf *TaskFuture) Receive() *Task
func (*TaskFuture) Return ¶
func (tf *TaskFuture) Return(out bool)
type TaskPayload ¶
type TaskPayload struct {
Payload []byte `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"`
}
func (*TaskPayload) Descriptor ¶
func (*TaskPayload) Descriptor() ([]byte, []int)
func (*TaskPayload) GetPayload ¶
func (m *TaskPayload) GetPayload() []byte
func (*TaskPayload) ProtoMessage ¶
func (*TaskPayload) ProtoMessage()
func (*TaskPayload) Reset ¶
func (m *TaskPayload) Reset()
func (*TaskPayload) String ¶
func (m *TaskPayload) String() string
type TaskPriority ¶
type TaskPriority interface {
GetPriority() taskPriority
}
Click to show internal directories.
Click to hide internal directories.