Workflow Engine .NET

Assembly: OptimaJet.Workflow.Core

Class OfflineApi

OptimaJet.Workflow.Core.Runtime.OfflineApi

public sealed class OfflineApi

Inheritance

  • System.Object

Constructors

public OfflineApi(WorkflowRuntime runtimeOwner) #

Parameters

Name
Type
Description
runtimeOwner
WorkflowRuntime

Methods

public Task<Dictionary<string, ActivityDto>> GetApprovalMapAsync(ProcessDefinition scheme, Func<TransitionDefinition, Task<bool>> predicate = null, bool ignoreSubprocesses = false) #
Get map of possible approval by process scheme

Parameters

Name
Type
Description
scheme
ProcessDefinition
predicate
Func<Boolean>
Additional validation for each transition
ignoreSubprocesses
Boolean
Ignore or not subprocesses on mapping

Returns

Type
Description
Task<ActivityDto>
Collection of activity (ActivityDto) and his transition (TransitionDto) in another activity
public Task<Dictionary<string, ActivityDto>> GetApprovalMapAsync(ProcessInstance pi, string identityId) #
Get map of possible approval by ProcessInstance for identity Id

Parameters

Name
Type
Description
pi
ProcessInstance
Process Instance
identityId
String
User id

Returns

Type
Description
Task<ActivityDto>
Collection of activity (ActivityDto) and his transition (TransitionDto) in another activity for identityId
public Task<List<CommandExecutionResult>> ExecuteSomeCommandsAsync(IEnumerable<Command> commands) #
Try to execute several commands grouped by processId and sorted by DateTime

Parameters

Name
Type
Description
commands
IEnumerable<Command>
Collection command for execute. In parameter ProcessId of Command is required for success execution

Returns

Type
Description
Task<CommandExecutionResult>
Result of execution for each command in some order like input commands
public Task<List<CommandExecutionResult>> ExecuteSomeCommandsAsync(Guid processId, IEnumerable<Command> commands) #
Try to execute several commands of one process sorted by DateTime

Parameters

Name
Type
Description
processId
Guid
Id of ProcessInstance for which the commands are executed
commands
IEnumerable<Command>
Collection command for execute. In this method parameter ProcessId of Command is ignored

Returns

Type
Description
Task<CommandExecutionResult>
Result of execution for each command in some order like input commands