Documentation ¶
Index ¶
- func ContinuePIByKey(ctx context.Context, piKey string) (engine_types.ProcessInstance, error)
- func CreatePIByByte(raw []byte, variables map[string]any) (engine_types.ProcessInstance, error)
- func CreatePIByID(processID string, variables map[string]any) (engine_types.ProcessInstance, error)
- func CreatePIByIDAndRun(ctx context.Context, processID string, variables map[string]any) (engine_types.ProcessInstance, error)
- func Engine() *engineContext
- func GetProcess(processID string) engine_types.Process
- func GetServiceTaskHandler(taskType string) (engine_types.TaskHandler, error)
- func LoadFromEmbed(myfs *embed.FS) error
- func LoadProcessInstance[T engine_types.ProcessInstance](raw []byte) (engine_types.ProcessInstance, error)
- func PublishEventForInstanceContinue(ctx context.Context, piKey string, messageName string, ...) (engine_types.ProcessInstance, error)
- func RegisterPICreateHandler(handler createHandler)
- func RegisterServiceTaskHandler(taskType string, fun engine_types.TaskHandler)
- func SaveProcessInstance(pi engine_types.ProcessInstance) ([]byte, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContinuePIByKey ¶
func ContinuePIByKey(ctx context.Context, piKey string) (engine_types.ProcessInstance, error)
func CreatePIByByte ¶
func CreatePIByByte(raw []byte, variables map[string]any) (engine_types.ProcessInstance, error)
创建新的流程实例
func CreatePIByID ¶
func CreatePIByID(processID string, variables map[string]any) (engine_types.ProcessInstance, error)
通过流程ID创建实例
func CreatePIByIDAndRun ¶
func CreatePIByIDAndRun(ctx context.Context, processID string, variables map[string]any) (engine_types.ProcessInstance, error)
func GetServiceTaskHandler ¶
func GetServiceTaskHandler(taskType string) (engine_types.TaskHandler, error)
获取 Servcie Task 元素处理函数
func LoadProcessInstance ¶
func LoadProcessInstance[T engine_types.ProcessInstance](raw []byte) (engine_types.ProcessInstance, error)
导入json文件
func PublishEventForInstanceContinue ¶
func PublishEventForInstanceContinue( ctx context.Context, piKey string, messageName string, variables map[string]any, ) (engine_types.ProcessInstance, error)
基于消息名称对流程进行重启
func RegisterServiceTaskHandler ¶
func RegisterServiceTaskHandler(taskType string, fun engine_types.TaskHandler)
注册 Servcie Task 元素处理函数
func SaveProcessInstance ¶
func SaveProcessInstance(pi engine_types.ProcessInstance) ([]byte, error)
保存为json文件
Types ¶
This section is empty.
Source Files ¶
Click to show internal directories.
Click to hide internal directories.