Documentation
¶
Index ¶
- Constants
- type CommandDescriptor
- type CommandEntrypoint
- type CommandInvocation
- type ExecutionState
- type Executor
- func (e *Executor) Register(descriptor *CommandDescriptor, names ...string) error
- func (e *Executor) Run(ib *bytes.Buffer, opts *CommandInvocation, ob *bytes.Buffer, eb *bytes.Buffer) (*ExecutionState, error)
- func (e *Executor) RunOnRawData(opts *CommandInvocation, inData []byte) ([]byte, []byte, *ExecutionState, error)
- type ExecutorOptions
- type PipeChain
- type TimeSecond
Constants ¶
View Source
const BLANK string = ""
View Source
const MAIN_RESOURCE string = ":default-resource:"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CommandDescriptor ¶
type CommandDescriptor struct {
CommandString string `json:"command"`
ExecutionTimeout TimeSecond `json:"timeout"`
// contains filtered or unexported fields
}
type CommandEntrypoint ¶
type CommandEntrypoint struct {
Default *CommandDescriptor `json:"default"`
Methods map[string]*CommandDescriptor `json:"methods"`
}
type CommandInvocation ¶
type CommandInvocation struct {
Envs []string
PriorCommand string
ResourceName string
MethodName string
ExecutionTimeout TimeSecond
}
type ExecutionState ¶
type Executor ¶
type Executor struct {
// contains filtered or unexported fields
}
func NewExecutor ¶
func NewExecutor(opts *ExecutorOptions) (*Executor, error)
func (*Executor) Register ¶
func (e *Executor) Register(descriptor *CommandDescriptor, names ...string) error
func (*Executor) Run ¶
func (e *Executor) Run(ib *bytes.Buffer, opts *CommandInvocation, ob *bytes.Buffer, eb *bytes.Buffer) (*ExecutionState, error)
func (*Executor) RunOnRawData ¶
func (e *Executor) RunOnRawData(opts *CommandInvocation, inData []byte) ([]byte, []byte, *ExecutionState, error)
type ExecutorOptions ¶
type ExecutorOptions struct {
DefaultCommand *CommandDescriptor
}
type PipeChain ¶
type PipeChain struct {
// contains filtered or unexported fields
}
type TimeSecond ¶ added in v1.0.2
type TimeSecond int
Click to show internal directories.
Click to hide internal directories.