flow

package
v0.0.2-beta Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 26, 2022 License: Apache-2.0 Imports: 9 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Validate

func Validate(wf *model.Workflow, container *container.DIContiner) error

Types

type Flow

type Flow struct {
	Id             string
	RootAction     int
	Actions        map[int]action.Action
	FailureHandler cluster.Statehandler
	SuccessHandler cluster.Statehandler
}

func Convert

func Convert(wf *model.Workflow, id string, container *container.DIContiner) *Flow

type FlowMachine

type FlowMachine struct {
	WorkflowName string
	FlowId       string

	CurrentAction action.Action
	// contains filtered or unexported fields
}

func GetFlowStateMachine

func GetFlowStateMachine(wfName string, flowId string, container *container.DIContiner) (*FlowMachine, error)

func NewFlowStateMachine

func NewFlowStateMachine(container *container.DIContiner) *FlowMachine

func (*FlowMachine) Execute

func (f *FlowMachine) Execute(tryCount int, actionId int) error

func (*FlowMachine) GetFlowState

func (f *FlowMachine) GetFlowState() model.FlowState

func (*FlowMachine) Init

func (f *FlowMachine) Init(wfName string, input map[string]any) error

func (*FlowMachine) MarkComplete

func (f *FlowMachine) MarkComplete()

func (*FlowMachine) MarkFailed

func (f *FlowMachine) MarkFailed()

func (*FlowMachine) MarkPaused

func (f *FlowMachine) MarkPaused()

func (*FlowMachine) MarkRunning

func (f *FlowMachine) MarkRunning()

func (*FlowMachine) MarkWaitingDelay

func (f *FlowMachine) MarkWaitingDelay()

func (*FlowMachine) MarkWaitingEvent

func (f *FlowMachine) MarkWaitingEvent()

func (*FlowMachine) MoveForward

func (f *FlowMachine) MoveForward(event string, dataMap map[string]any) (bool, error)

func (*FlowMachine) ValidateExecutionRequest

func (f *FlowMachine) ValidateExecutionRequest(actionId int) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL