Versions in this module Expand all Collapse all v1 v1.0.0 Jan 2, 2024 Changes in this version + const OpRestart + const OpResume + const OpStart + func ApplyExecOptions(instance *IndependentInstance, execOptions *ExecOptions) + func EnableChangeTracking(enable bool, mode state.RecordingMode) + func GetFlowIOMetadata(flowURI string) (*metadata.IOMetadata, error) + func NewErrorObj(taskId string, msg string) map[string]interface + func NewStateInstanceRecorder(recorder state.Recorder, mod state.RecordingMode, rerunstate bool) *stateInstanceRecorder + func StartSubFlow(ctx activity.Context, flowURI string, inputs map[string]interface{}) error + type ActivityEvalError struct + func NewActivityEvalError(taskName string, errorType string, errorText string) *ActivityEvalError + func (e *ActivityEvalError) Error() string + func (e *ActivityEvalError) TaskName() string + func (e *ActivityEvalError) Type() string + type ChangeTracker interface + AttrChange func(subflowId int, name string, value interface{}) + ExtractStep func(reset bool) *state.Step + FlowCreated func(flow *IndependentInstance) + FlowDone func(flow *IndependentInstance) + LinkAdded func(linkInst *LinkInst) + LinkRemoved func(subflowId int, linkId int) + LinkUpdated func(linkInst *LinkInst) + SetStatus func(subflowId int, status model.FlowStatus) + SubflowCreated func(subflow *Instance) + SubflowDone func(subflow *Instance) + TaskAdded func(taskInst *TaskInst) + TaskRemoved func(subflowId int, taskId string) + TaskUpdated func(taskInst *TaskInst) + WorkItemAdded func(wi *WorkItem) + WorkItemRemoved func(wi *WorkItem) + func NewInstanceChangeTracker(flowId string, startStepId int) ChangeTracker + type ExecOptions struct + Interceptor *support.Interceptor + Patch *support.Patch + type IDGenerator interface + NewFlowInstanceID func() string + type IDResponse struct + ID string + type IndependentInstance struct + func NewIndependentInstance(instanceID string, flowURI string, flow *definition.Definition, ...) (*IndependentInstance, error) + func (inst *IndependentInstance) ApplyInterceptor(interceptor *flowsupport.Interceptor) + func (inst *IndependentInstance) ApplyPatch(patch *flowsupport.Patch) + func (inst *IndependentInstance) CurrentStep(reset bool) *state.Step + func (inst *IndependentInstance) DoStep() bool + func (inst *IndependentInstance) ExecutionTime() time.Duration + func (inst *IndependentInstance) GetChanges() ChangeTracker + func (inst *IndependentInstance) GetFlowState(inputs map[string]interface{}) *state.FlowState + func (inst *IndependentInstance) GetInterceptor() *flowsupport.Interceptor + func (inst *IndependentInstance) HandleGlobalError(containerInst *Instance, err error) + func (inst *IndependentInstance) MarshalJSON() ([]byte, error) + func (inst *IndependentInstance) RecordState(strtTime time.Time) error + func (inst *IndependentInstance) ResetChanges() + func (inst *IndependentInstance) Restart(logger log.Logger, id string, initStepId int) error + func (inst *IndependentInstance) SetInstanceRecorder(stateRecorder *stateInstanceRecorder) + func (inst *IndependentInstance) SetTracingContext(tracingCtx trace.TracingContext) + func (inst *IndependentInstance) Snapshot() *state.Snapshot + func (inst *IndependentInstance) Start(startAttrs map[string]interface{}) bool + func (inst *IndependentInstance) StepID() int + func (inst *IndependentInstance) UnmarshalJSON(d []byte) error + func (inst *IndependentInstance) UpdateStartTime() + type Instance struct + func (inst *Instance) FindOrCreateLinkData(link *definition.Link) (linkInst *LinkInst, created bool) + func (inst *Instance) FindOrCreateTaskInst(task *definition.Task) (taskInst *TaskInst, created bool) + func (inst *Instance) FlowDefinition() *definition.Definition + func (inst *Instance) FlowURI() string + func (inst *Instance) GetError() error + func (inst *Instance) GetMasterScope() data.Scope + func (inst *Instance) GetReturnData() (map[string]interface{}, error) + func (inst *Instance) GetValue(name string) (value interface{}, exists bool) + func (inst *Instance) ID() string + func (inst *Instance) IOMetadata() *metadata.IOMetadata + func (inst *Instance) Logger() log.Logger + func (inst *Instance) MarshalJSON() ([]byte, error) + func (inst *Instance) Name() string + func (inst *Instance) Reply(replyData map[string]interface{}, err error) + func (inst *Instance) Return(returnData map[string]interface{}, err error) + func (inst *Instance) Scope() data.Scope + func (inst *Instance) SetResultHandler(handler action.ResultHandler) + func (inst *Instance) SetStatus(status model.FlowStatus) + func (inst *Instance) SetValue(name string, value interface{}) error + func (inst *Instance) SpanConfig() trace.Config + func (inst *Instance) Status() model.FlowStatus + func (inst *Instance) TaskInstances() []model.TaskInstance + func (inst *Instance) TracingContext() trace.TracingContext + func (inst *Instance) UnmarshalJSON(d []byte) error + func (inst *Instance) UpdateAttrs(attrs map[string]interface{}) + type LegacyCtx struct + func (l *LegacyCtx) ActivityHost() activity.Host + func (l *LegacyCtx) GetInput(name string) interface{} + func (l *LegacyCtx) GetInputObject(input data.StructValue) error + func (l *LegacyCtx) GetInputSchema(name string) schema.Schema + func (l *LegacyCtx) GetOutput(name string) interface{} + func (l *LegacyCtx) GetOutputSchema(name string) schema.Schema + func (l *LegacyCtx) GetSetting(name string) (interface{}, bool) + func (l *LegacyCtx) GetSharedTempData() map[string]interface{} + func (l *LegacyCtx) GetTracingContext() trace.TracingContext + func (l *LegacyCtx) Logger() log.Logger + func (l *LegacyCtx) Name() string + func (l *LegacyCtx) SetOutput(name string, value interface{}) error + func (l *LegacyCtx) SetOutputObject(output data.StructValue) error + type LinkInst struct + func NewLinkInst(inst *Instance, link *definition.Link) *LinkInst + func (li *LinkInst) Link() *definition.Link + func (li *LinkInst) MarshalJSON() ([]byte, error) + func (li *LinkInst) SetStatus(status model.LinkStatus) + func (li *LinkInst) Status() model.LinkStatus + func (li *LinkInst) UnmarshalJSON(d []byte) error + type NoopChangeTracker struct + func (nct *NoopChangeTracker) AttrChange(subflowId int, name string, value interface{}) + func (nct *NoopChangeTracker) ExtractStep(reset bool) *state.Step + func (nct *NoopChangeTracker) FlowCreated(flow *IndependentInstance) + func (nct *NoopChangeTracker) FlowDone(flow *IndependentInstance) + func (nct *NoopChangeTracker) LinkAdded(linkInst *LinkInst) + func (nct *NoopChangeTracker) LinkRemoved(subflowId int, linkId int) + func (nct *NoopChangeTracker) LinkUpdated(linkInst *LinkInst) + func (nct *NoopChangeTracker) SetStatus(subflowId int, status model.FlowStatus) + func (nct *NoopChangeTracker) SubflowCreated(subflow *Instance) + func (nct *NoopChangeTracker) SubflowDone(subflow *Instance) + func (nct *NoopChangeTracker) TaskAdded(taskInst *TaskInst) + func (nct *NoopChangeTracker) TaskRemoved(subflowId int, taskId string) + func (nct *NoopChangeTracker) TaskUpdated(taskInst *TaskInst) + func (nct *NoopChangeTracker) WorkItemAdded(wi *WorkItem) + func (nct *NoopChangeTracker) WorkItemRemoved(wi *WorkItem) + type RunOptions struct + ExecOptions *ExecOptions + FlowURI string + InitStepId int + InitialState *IndependentInstance + Op int + OriginalInstanceId string + PreservedInstanceId string + Rerun bool + ReturnID bool + type SimpleChangeTracker struct + func (sct *SimpleChangeTracker) AttrChange(subflowId int, name string, value interface{}) + func (sct *SimpleChangeTracker) ExtractStep(reset bool) *state.Step + func (sct *SimpleChangeTracker) FlowCreated(flow *IndependentInstance) + func (sct *SimpleChangeTracker) FlowDone(flow *IndependentInstance) + func (sct *SimpleChangeTracker) LinkAdded(linkInst *LinkInst) + func (sct *SimpleChangeTracker) LinkRemoved(subflowId int, linkId int) + func (sct *SimpleChangeTracker) LinkUpdated(linkInst *LinkInst) + func (sct *SimpleChangeTracker) SetStatus(subflowId int, status model.FlowStatus) + func (sct *SimpleChangeTracker) SubflowCreated(subflow *Instance) + func (sct *SimpleChangeTracker) SubflowDone(subflow *Instance) + func (sct *SimpleChangeTracker) TaskAdded(taskInst *TaskInst) + func (sct *SimpleChangeTracker) TaskRemoved(subflowId int, taskId string) + func (sct *SimpleChangeTracker) TaskUpdated(taskInst *TaskInst) + func (sct *SimpleChangeTracker) WorkItemAdded(wi *WorkItem) + func (sct *SimpleChangeTracker) WorkItemRemoved(wi *WorkItem) + type SimpleChangeTrackerFactory struct + func (sf *SimpleChangeTrackerFactory) NewChangeTracker(flowId string, mode state.RecordingMode, startStepId int) ChangeTracker + type TaskInst struct + func NewTaskInst(flowInst *Instance, task *definition.Task) *TaskInst + func (ti *TaskInst) ActivityHost() activity.Host + func (ti *TaskInst) EvalActivity() (done bool, evalErr error) + func (ti *TaskInst) EvalLink(link *definition.Link) (result bool, err error) + func (ti *TaskInst) FlowLogger() log.Logger + func (ti *TaskInst) GetFromLinkInstances() []model.LinkInstance + func (ti *TaskInst) GetInput(name string) interface{} + func (ti *TaskInst) GetInputObject(input data.StructValue) error + func (ti *TaskInst) GetInputSchema(name string) schema.Schema + func (ti *TaskInst) GetOutputSchema(name string) schema.Schema + func (ti *TaskInst) GetSetting(name string) (value interface{}, exists bool) + func (ti *TaskInst) GetSharedTempData() map[string]interface{} + func (ti *TaskInst) GetToLinkInstances() []model.LinkInstance + func (ti *TaskInst) GetTracingContext() trace.TracingContext + func (ti *TaskInst) GetWorkingData(key string) (interface{}, bool) + func (ti *TaskInst) GetWorkingDataScope() *WorkingDataScope + func (ti *TaskInst) HasActivity() bool + func (ti *TaskInst) InstanceId() string + func (ti *TaskInst) Logger() log.Logger + func (ti *TaskInst) MarshalJSON() ([]byte, error) + func (ti *TaskInst) Name() string + func (ti *TaskInst) PostEvalActivity() (done bool, evalErr error) + func (ti *TaskInst) SetOutput(name string, value interface{}) error + func (ti *TaskInst) SetOutputObject(output data.StructValue) error + func (ti *TaskInst) SetOutputs(outputs map[string]interface{}) error + func (ti *TaskInst) SetStatus(status model.TaskStatus) + func (ti *TaskInst) SetWorkingData(key string, value interface{}) + func (ti *TaskInst) SpanConfig() trace.Config + func (ti *TaskInst) Status() model.TaskStatus + func (ti *TaskInst) Task() *definition.Task + func (ti *TaskInst) UnmarshalJSON(d []byte) error + func (ti *TaskInst) UpdateTaskToTracker() + type WorkItem struct + ID int + SubFlowID int + TaskID string + func NewWorkItem(id int, taskInst *TaskInst) *WorkItem + type WorkingDataScope struct + func NewWorkingDataScope(parentScope data.Scope) *WorkingDataScope + func (s *WorkingDataScope) GetValue(name string) (value interface{}, exists bool) + func (s *WorkingDataScope) GetWorkingValue(name string) (value interface{}, exists bool) + func (s *WorkingDataScope) SetValue(name string, value interface{}) error + func (s *WorkingDataScope) SetWorkingValue(name string, value interface{})