Package com.yworkflow.instance.session
Interface WorkflowSession
public interface WorkflowSession
Represents a session for workflow instance execution. WorkflowSession provides access to all the
necessary components and context for executing workflow instances, including extensions,
properties, attributes, and storage.
-
Method Summary
Modifier and TypeMethodDescriptionactAs(WorkflowCaller caller) Creates a new session acting as the specified caller.Gets the caller context for this session.getClock()Gets the workflow clock for this session.Gets the workflow definition for this session.Gets the extension provider for this session.Gets the global attributes for this session.Gets the properties for this session.getStore()Gets the workflow instance store for this session.start(Attributes inputs) with(WorkflowCallerContext callerContext) Creates a new session with the specified caller context.
-
Method Details
-
getExtensions
ExtensionProvider getExtensions()Gets the extension provider for this session.- Returns:
- the extension provider
-
getProperties
Properties getProperties()Gets the properties for this session.- Returns:
- the session properties
-
getGlobalAttributes
Attributes getGlobalAttributes()Gets the global attributes for this session.- Returns:
- the global attributes
-
getDefinition
WorkflowDefinition getDefinition()Gets the workflow definition for this session.- Returns:
- the workflow definition
-
getCallerContext
WorkflowCallerContext getCallerContext()Gets the caller context for this session.- Returns:
- the caller context
-
getStore
WorkflowInstanceStore getStore()Gets the workflow instance store for this session.- Returns:
- the workflow instance store
-
getClock
WorkflowClock getClock()Gets the workflow clock for this session.- Returns:
- the workflow clock
-
with
Creates a new session with the specified caller context.- Parameters:
callerContext- the new caller context- Returns:
- a new WorkflowSession with the specified caller context
-
actAs
Creates a new session acting as the specified caller.- Parameters:
caller- the caller to act as- Returns:
- a new WorkflowSession acting as the specified caller
-
start
- Parameters:
inputs- the inputs to set in the execution context- Returns:
- return a mutable execution context
-