public class ExecutionImpl extends Object implements Serializable, ActivityExecution, ExecutionListenerExecution, PvmExecution, InterpretableExecution
| Modifier and Type | Field and Description |
|---|---|
protected ActivityImpl |
activity
current activity
|
protected FlowElement |
currentFlowElement |
protected String |
deleteReason |
protected boolean |
deleteRoot |
protected String |
eventName |
protected PvmProcessElement |
eventSource |
protected int |
executionListenerIndex |
protected List<ExecutionImpl> |
executions
nested executions representing scopes or concurrent paths
|
protected boolean |
isActive
indicates if this execution represents an active path of execution.
|
protected boolean |
isConcurrent |
protected boolean |
isEnded |
protected boolean |
isEventScope |
protected boolean |
isOperating |
protected boolean |
isScope |
protected AtomicOperation |
nextOperation
next operation.
|
protected ExecutionImpl |
parent
the parent execution
|
protected ProcessDefinitionImpl |
processDefinition |
protected ExecutionImpl |
processInstance
the process instance.
|
protected ExecutionImpl |
replacedBy
when execution structure is pruned during a takeAll, then the original execution has to be resolved to the replaced execution.
|
protected StartingExecution |
startingExecution
only available until the process instance is started
|
protected ExecutionImpl |
subProcessInstance
reference to a subprocessinstance, not-null if currently subprocess is started from this execution
|
protected ExecutionImpl |
superExecution
super execution, not-null if this execution is part of a subprocess
|
protected TransitionImpl |
transition
current transition.
|
protected Map<String,Object> |
variables |
| Constructor and Description |
|---|
ExecutionImpl() |
ExecutionImpl(ActivityImpl initial) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
collectActiveActivityIds(List<String> activeActivityIds) |
protected void |
collectVariables(Map<String,Object> collectedVariables) |
ExecutionImpl |
createExecution()
creates a new execution.
|
PvmProcessInstance |
createSubProcessInstance(PvmProcessDefinition processDefinition)
creates a new sub process instance.
|
void |
createVariableLocal(String variableName,
Object value) |
void |
createVariablesLocal(Map<String,? extends Object> variables) |
void |
deleteCascade(String deleteReason) |
void |
deleteVariablesLocal() |
void |
destroy() |
void |
destroyScope(String reason)
Called when an execution is interrupted.
|
void |
disposeStartingExecution() |
void |
end()
removes an execution.
|
protected void |
ensureActivityInitialized()
must be called before the activity member field or getActivity() is called
|
protected void |
ensureExecutionsInitialized()
must be called before memberfield executions is used.
|
protected void |
ensureParentInitialized()
must be called before memberfield parent is used.
|
protected void |
ensureProcessDefinitionInitialized() |
protected void |
ensureProcessInstanceInitialized()
must be called before memberfield processInstance is used.
|
protected void |
ensureScopeInitialized() |
protected void |
ensureSubProcessInstanceInitialized() |
protected void |
ensureSuperExecutionInitialized() |
protected void |
ensureVariablesInitialized() |
void |
executeActivity(PvmActivity activity)
Executes the
ActivityBehavior associated with the given activity. |
List<String> |
findActiveActivityIds() |
ExecutionImpl |
findExecution(String activityId)
searches for an execution positioned in the given activity
|
List<ActivityExecution> |
findInactiveConcurrentExecutions(PvmActivity activity)
Retrieves all executions which are concurrent and inactive at the given activity.
|
ActivityImpl |
getActivity()
ensures initialization and returns the activity
|
String |
getBusinessKey() |
String |
getCurrentActivityId()
Gets the id of the current activity.
|
String |
getCurrentActivityName() |
FlowableListener |
getCurrentFlowableListener()
Returns the
FlowableListener instance matching an ExecutionListener if currently an execution listener is being execution. |
FlowElement |
getCurrentFlowElement()
The BPMN element where the execution currently is at.
|
String |
getDeleteReason() |
String |
getEventName()
Will contain the event name in case this execution is passed in for an
ExecutionListener. |
PvmProcessElement |
getEventSource() |
Integer |
getExecutionListenerIndex() |
List<ExecutionImpl> |
getExecutions()
ensures initialization and returns the non-null executions list
|
String |
getId()
Unique id of this path of execution that can be used as a handle to provide external signals back into the engine after wait states.
|
ExecutionImpl |
getParent()
ensures initialization and returns the parent
|
String |
getParentId()
Gets the id of the parent of this execution.
|
ProcessDefinitionImpl |
getProcessDefinition()
ensures initialization and returns the process definition.
|
String |
getProcessDefinitionId()
The process definition key for the process instance this execution is associated with.
|
ExecutionImpl |
getProcessInstance()
ensures initialization and returns the process instance.
|
String |
getProcessInstanceBusinessKey()
The business key for the process instance this execution is associated with.
|
String |
getProcessInstanceId()
Reference to the overall process instance
|
String |
getPropagatedStageInstanceId()
If this execution runs in the context of a case and stage, this method returns it's closest parent stage instance id (the stage plan item instance id to be
precise).
|
ExecutionImpl |
getReplacedBy() |
String |
getRootProcessInstanceId()
The 'root' process instance.
|
StartingExecution |
getStartingExecution() |
ExecutionImpl |
getSubProcessInstance() |
ExecutionImpl |
getSuperExecution() |
String |
getSuperExecutionId()
Gets the id of the calling execution.
|
String |
getTenantId()
Returns the tenant id, if any is set before on the process definition or process instance.
|
protected String |
getToStringIdentity() |
Object |
getTransientVariable(String variableName)
Similar to
VariableScope.getVariable(String), including the searching via the parent scopes, but for transient variables only. |
Object |
getTransientVariableLocal(String variableName)
Similar to
VariableScope.getVariableLocal(String), but for a transient variable. |
Map<String,Object> |
getTransientVariables()
Similar to
VariableScope.getVariables(), but for transient variables only. |
Map<String,Object> |
getTransientVariablesLocal()
Similar to
VariableScope.getVariableLocal(String), but for transient variables only. |
TransitionImpl |
getTransition() |
Object |
getVariable(String variableName)
Returns the variable value for one specific variable.
|
Object |
getVariable(String variableName,
boolean fetchAllVariables)
Similar to
VariableScope.getVariable(String), but has an extra flag that indicates whether or not all variables need to be fetched when getting one variable. |
<T> T |
getVariable(String variableName,
Class<T> variableClass)
Typed version of the
VariableScope.getVariable(String) method. |
VariableInstance |
getVariableInstance(String variableName)
Similar to
VariableScope.getVariable(String), but returns a VariableInstance instance, which contains more information than just the value. |
VariableInstance |
getVariableInstance(String variableName,
boolean fetchAllVariables)
Similar to
VariableScope.getVariable(String, boolean), but returns an instance of VariableInstance, which has some additional information beyond the value. |
VariableInstanceEntity |
getVariableInstanceLocal(String variableName)
Similar to
VariableScope.getVariableLocal(String), but returns an instance of VariableInstance, which has some additional information beyond the value. |
VariableInstanceEntity |
getVariableInstanceLocal(String variableName,
boolean fetchAllVariables)
Similar to
VariableScope.getVariableLocal(String, boolean), but returns an instance of VariableInstance, which has some additional information beyond the value. |
Map<String,VariableInstance> |
getVariableInstances()
Returns all variables, as instances of the
VariableInstance interface, which gives more information than only the value (type, execution id, etc.) |
Map<String,VariableInstance> |
getVariableInstances(Collection<String> variableNames)
Similar to
VariableScope.getVariableInstances(), but limited to only the variables with the provided names. |
Map<String,VariableInstance> |
getVariableInstances(Collection<String> variableNames,
boolean fetchAllVariables)
Similar to
VariableScope.getVariables(Collection, boolean) but returns the variables as instances of the VariableInstance interface, which gives more information than only the value
(type, execution id, etc.) |
Map<String,VariableInstance> |
getVariableInstancesLocal()
Returns the variables local to this scope as instances of the
VariableInstance interface, which provided additional information about the variable. |
Map<String,VariableInstance> |
getVariableInstancesLocal(Collection<String> variableNames)
Similar to
VariableScope.getVariableInstances(Collection), but only for variables local to this scope. |
Map<String,VariableInstance> |
getVariableInstancesLocal(Collection<String> variableNames,
boolean fetchAllVariables)
Similar to
VariableScope.getVariableInstances(Collection, boolean), but only for variables local to this scope. |
Object |
getVariableLocal(String variableName)
Returns the value for the specific variable and only checks this scope and not any parent scope.
|
Object |
getVariableLocal(String variableName,
boolean fetchAllVariables)
Similar to
VariableScope.getVariableLocal(String), but has an extra flag that indicates whether or not all variables need to be fetched when getting one variable. |
<T> T |
getVariableLocal(String variableName,
Class<T> variableClass)
Typed version of the
VariableScope.getVariableLocal(String) method. |
Set<String> |
getVariableNames()
Returns all the names of the variables for this scope and all parent scopes.
|
Set<String> |
getVariableNamesLocal()
Returns all the names of the variables for this scope (no parent scopes).
|
Map<String,Object> |
getVariables()
Returns all variables.
|
Map<String,Object> |
getVariables(Collection<String> variableNames)
Similar to
VariableScope.getVariables(), but limited to only the variables with the provided names. |
Map<String,Object> |
getVariables(Collection<String> variableNames,
boolean fetchAllVariables)
Similar to
VariableScope.getVariables(Collection), but with a flag that indicates that all variables should be fetched when fetching the specific variables. |
Map<String,Object> |
getVariablesLocal()
Returns the variable local to this scope only.
|
Map<String,Object> |
getVariablesLocal(Collection<String> variableNames)
Similar to
VariableScope.getVariables(Collection), but only for variables local to this scope. |
Map<String,Object> |
getVariablesLocal(Collection<String> variableNames,
boolean fetchAllVariables)
Similar to
VariableScope.getVariables(Collection, boolean), but only for variables local to this scope. |
boolean |
hasVariable(String variableName)
Returns whether this scope or any parent scope has a specific variable.
|
boolean |
hasVariableLocal(String variableName)
Returns whether this scope has a specific variable.
|
boolean |
hasVariables()
Returns whether this scope or any parent scope has variables.
|
boolean |
hasVariablesLocal()
Returns whether this scope has variables.
|
void |
inactivate()
Inactivates this execution.
|
void |
initialize() |
boolean |
isActive()
returns whether this execution is currently active.
|
boolean |
isActive(String activityId) |
boolean |
isConcurrent()
returns whether this execution is concurrent or not.
|
boolean |
isDeleteRoot() |
boolean |
isEnded()
returns whether this execution has ended or not.
|
boolean |
isEventScope() |
boolean |
isMultiInstanceRoot()
Returns whether this execution is the root of a multi instance execution.
|
boolean |
isProcessInstanceType()
returns whether this execution is a process instance or not.
|
boolean |
isScope()
Returns whether this execution is a scope.
|
protected ExecutionImpl |
newExecution()
instantiates a new execution.
|
void |
performOperation(AtomicOperation executionOperation) |
void |
remove() |
void |
removeTransientVariable(String variableName)
Removes a specific transient variable.
|
void |
removeTransientVariableLocal(String variableName)
Removes a specific transient variable (also searching parent scopes).
|
void |
removeTransientVariables()
Remove all transient variable of this scope and its parent scopes.
|
void |
removeTransientVariablesLocal()
Removes all local transient variables.
|
void |
removeVariable(String variableName)
Removes the variable and creates a new HistoricVariableUpdate.
|
void |
removeVariableLocal(String variableName)
Removes the local variable and creates a new HistoricVariableUpdate.
|
void |
removeVariables()
Removes the (local) variables and creates a new HistoricVariableUpdate for each of them.
|
void |
removeVariables(Collection<String> variableNames)
Removes the variables and creates a new HistoricVariableUpdate for each of them.
|
void |
removeVariablesLocal()
Removes the (local) variables and creates a new HistoricVariableUpdate for each of them.
|
void |
removeVariablesLocal(Collection<String> variableNames)
Removes the local variables and creates a new HistoricVariableUpdate for each of them.
|
void |
setActive(boolean isActive)
makes this execution active or inactive.
|
void |
setActivity(ActivityImpl activity)
sets the current activity.
|
void |
setConcurrent(boolean isConcurrent)
changes the concurrent indicator on this execution.
|
void |
setCurrentFlowableListener(FlowableListener currentListener)
Called when an
ExecutionListener is being executed. |
void |
setCurrentFlowElement(FlowElement currentFlowElement)
Change the current BPMN element the execution is at.
|
void |
setDeleteReason(String deleteReason) |
void |
setEnded(boolean ended)
Sets whether this execution is ended or not.
|
void |
setEventName(String eventName)
Sets the current event (typically when execution an
ExecutionListener). |
void |
setEventScope(boolean isEventScope) |
void |
setEventSource(PvmProcessElement eventSource) |
void |
setExecutionListenerIndex(Integer executionListenerIndex) |
void |
setExecutions(List<ExecutionImpl> executions) |
void |
setMultiInstanceRoot(boolean isMultiInstanceRoot)
Changes whether this execution is a multi instance root or not.
|
void |
setParent(InterpretableExecution parent)
all updates need to go through this setter as subclasses can override this method
|
void |
setProcessDefinition(ProcessDefinitionImpl processDefinition) |
void |
setProcessInstance(InterpretableExecution processInstance)
for setting the process instance, this setter must be used as subclasses can override
|
void |
setReplacedBy(InterpretableExecution replacedBy) |
void |
setScope(boolean isScope)
Changes whether this execution is a scope or not
|
void |
setSubProcessInstance(InterpretableExecution subProcessInstance) |
void |
setSuperExecution(ExecutionImpl superExecution) |
void |
setTransientVariable(String variableName,
Object variableValue)
Similar to
VariableScope.setVariable(String, Object), but the variable is transient:
- no history is kept for the variable - the variable is only available until a waitstate is reached in the process - transient variables 'shadow' persistent variable (when getVariable('abc')
where 'abc' is both persistent and transient, the transient value is returned. |
void |
setTransientVariableLocal(String variableName,
Object variableValue)
Similar to
VariableScope.setVariableLocal(String, Object), but for a transient variable. |
void |
setTransientVariables(Map<String,Object> transientVariables)
Similar to
VariableScope.setVariables(Map), but for transient variables. |
void |
setTransientVariablesLocal(Map<String,Object> transientVariables)
Similar to
VariableScope.setVariablesLocal(Map), but for transient variables. |
void |
setTransition(TransitionImpl transition) |
void |
setVariable(String variableName,
Object value)
Sets the variable with the provided name to the provided value.
|
void |
setVariable(String variableName,
Object value,
boolean fetchAllVariables)
Similar to
VariableScope.setVariable(String, Object), but with an extra flag to indicate whether all variables should be fetched while doing this or not. |
Object |
setVariableLocal(String variableName,
Object value)
Similar to
VariableScope.setVariable(String, Object), but the variable is set to this scope specifically. |
Object |
setVariableLocal(String variableName,
Object value,
boolean fetchAllVariables)
Similar to
VariableScope.setVariableLocal(String, Object), but with an extra flag to indicate whether all variables should be fetched while doing this or not. |
void |
setVariableLocally(String variableName,
Object value) |
void |
setVariables(Map<String,? extends Object> variables)
Sets the provided variables to the variable scope.
|
void |
setVariablesLocal(Map<String,? extends Object> variables)
Similar to
VariableScope.setVariables(Map), but the variable are set on this scope specifically. |
void |
signal(String signalName,
Object signalData) |
ReadOnlyDelegateExecution |
snapshotReadOnly()
Create a snapshot read only delegate execution of this delegate execution.
|
void |
start() |
void |
take(PvmTransition transition)
leaves the current activity by taking the given transition.
|
void |
take(PvmTransition transition,
boolean fireActivityCompletedEvent) |
void |
takeAll(List<PvmTransition> transitions,
List<ActivityExecution> recyclableExecutions)
Takes the given outgoing transitions, and potentially reusing the given list of executions that were previously joined.
|
String |
toString() |
String |
updateProcessBusinessKey(String bzKey) |
protected ProcessDefinitionImpl processDefinition
protected ActivityImpl activity
protected FlowElement currentFlowElement
protected TransitionImpl transition
protected ExecutionImpl processInstance
protected ExecutionImpl parent
protected List<ExecutionImpl> executions
protected ExecutionImpl superExecution
protected ExecutionImpl subProcessInstance
protected StartingExecution startingExecution
protected boolean isActive
protected boolean isScope
protected boolean isConcurrent
protected boolean isEnded
protected boolean isEventScope
protected String eventName
protected PvmProcessElement eventSource
protected int executionListenerIndex
protected boolean deleteRoot
protected String deleteReason
protected ExecutionImpl replacedBy
{@link OutgoingExecution}protected AtomicOperation nextOperation
AtomicOperation,
performOperation(AtomicOperation)protected boolean isOperating
public ExecutionImpl()
public ExecutionImpl(ActivityImpl initial)
public ExecutionImpl createExecution()
createExecution in interface ActivityExecutionprotected ExecutionImpl newExecution()
public PvmProcessInstance createSubProcessInstance(PvmProcessDefinition processDefinition)
ActivityExecutioncreateSubProcessInstance in interface ActivityExecutionprocessDefinition - The PvmProcessDefinition of the subprocess.public void initialize()
initialize in interface InterpretableExecutionpublic void destroy()
destroy in interface InterpretableExecutionpublic void remove()
remove in interface InterpretableExecutionpublic void destroyScope(String reason)
ActivityExecutiondestroyScope in interface ActivityExecutionpublic ExecutionImpl getParent()
getParent in interface ActivityExecutiongetParent in interface DelegateExecutionpublic String getSuperExecutionId()
DelegateExecutiongetSuperExecutionId in interface DelegateExecutionpublic String getParentId()
DelegateExecutiongetParentId in interface DelegateExecutionpublic void setParent(InterpretableExecution parent)
setParent in interface InterpretableExecutionprotected void ensureParentInitialized()
public List<ExecutionImpl> getExecutions()
getExecutions in interface ActivityExecutiongetExecutions in interface DelegateExecutionpublic ExecutionImpl getSuperExecution()
getSuperExecution in interface InterpretableExecutionpublic void setSuperExecution(ExecutionImpl superExecution)
protected void ensureSuperExecutionInitialized()
public ExecutionImpl getSubProcessInstance()
getSubProcessInstance in interface InterpretableExecutionpublic void setSubProcessInstance(InterpretableExecution subProcessInstance)
setSubProcessInstance in interface InterpretableExecutionprotected void ensureSubProcessInstanceInitialized()
public void deleteCascade(String deleteReason)
deleteCascade in interface PvmProcessInstancedeleteCascade in interface InterpretableExecutionpublic void end()
end in interface ActivityExecutionpublic ExecutionImpl findExecution(String activityId)
findExecution in interface PvmProcessInstancepublic List<String> findActiveActivityIds()
findActiveActivityIds in interface PvmProcessInstanceprotected void ensureExecutionsInitialized()
public ProcessDefinitionImpl getProcessDefinition()
getProcessDefinition in interface InterpretableExecutionpublic String getProcessDefinitionId()
DelegateExecutiongetProcessDefinitionId in interface DelegateExecutionprotected void ensureProcessDefinitionInitialized()
public ExecutionImpl getProcessInstance()
getProcessInstance in interface ActivityExecutionpublic String getProcessInstanceId()
DelegateExecutiongetProcessInstanceId in interface DelegateExecutionpublic String getRootProcessInstanceId()
DelegateExecutiongetRootProcessInstanceId in interface DelegateExecutionpublic String getBusinessKey()
public String getProcessInstanceBusinessKey()
DelegateExecutiongetProcessInstanceBusinessKey in interface DelegateExecutionpublic void setProcessInstance(InterpretableExecution processInstance)
setProcessInstance in interface InterpretableExecutionprotected void ensureProcessInstanceInitialized()
public ReadOnlyDelegateExecution snapshotReadOnly()
DelegateExecutionsnapshotReadOnly in interface DelegateExecutionReadOnlyDelegateExecutionpublic FlowElement getCurrentFlowElement()
DelegateExecutiongetCurrentFlowElement in interface DelegateExecutionpublic void setCurrentFlowElement(FlowElement currentFlowElement)
DelegateExecutionsetCurrentFlowElement in interface DelegateExecutionpublic FlowableListener getCurrentFlowableListener()
DelegateExecutionFlowableListener instance matching an ExecutionListener if currently an execution listener is being execution. Returns null otherwise.getCurrentFlowableListener in interface DelegateExecutionpublic void setCurrentFlowableListener(FlowableListener currentListener)
DelegateExecutionExecutionListener is being executed.setCurrentFlowableListener in interface DelegateExecutionpublic ActivityImpl getActivity()
getActivity in interface ActivityExecutiongetActivity in interface PvmExecutionpublic void setActivity(ActivityImpl activity)
setActivity in interface InterpretableExecutionprotected void ensureActivityInitialized()
protected void ensureScopeInitialized()
public boolean isScope()
ActivityExecutionisScope in interface ActivityExecutionisScope in interface InterpretableExecutionisScope in interface DelegateExecutionpublic void setScope(boolean isScope)
ActivityExecutionsetScope in interface ActivityExecutionsetScope in interface DelegateExecutionpublic void start()
start in interface PvmProcessInstancepublic void signal(String signalName, Object signalData)
signal in interface PvmExecutionpublic void take(PvmTransition transition, boolean fireActivityCompletedEvent)
take in interface InterpretableExecutionpublic void take(PvmTransition transition)
ActivityExecutiontake in interface ActivityExecutiontake in interface InterpretableExecutionpublic void executeActivity(PvmActivity activity)
ActivityExecutionActivityBehavior associated with the given activity.executeActivity in interface ActivityExecutionpublic List<ActivityExecution> findInactiveConcurrentExecutions(PvmActivity activity)
ActivityExecutionfindInactiveConcurrentExecutions in interface ActivityExecutionpublic void takeAll(List<PvmTransition> transitions, List<ActivityExecution> recyclableExecutions)
ActivityExecutiontakeAll in interface ActivityExecutionpublic void performOperation(AtomicOperation executionOperation)
performOperation in interface InterpretableExecutionpublic boolean isActive(String activityId)
public Object getVariable(String variableName)
VariableScopegetVariable in interface PvmExecutiongetVariable in interface VariableContainergetVariable in interface VariableScopepublic Object getVariable(String variableName, boolean fetchAllVariables)
VariableScopeVariableScope.getVariable(String), but has an extra flag that indicates whether or not all variables need to be fetched when getting one variable.
By default true (for backwards compatibility reasons), which means that calling VariableScope.getVariable(String) will fetch all variables, of the current scope and all parent scopes. Setting this
flag to false can thus be better for performance. However, variables are cached, and if other variables are used later on, setting this true might actually be better for performance.getVariable in interface VariableScopepublic Map<String,Object> getVariables()
VariableScopegetVariables in interface PvmExecutiongetVariables in interface VariableScopepublic Map<String,Object> getVariables(Collection<String> variableNames)
VariableScopeVariableScope.getVariables(), but limited to only the variables with the provided names.getVariables in interface VariableScopepublic Map<String,Object> getVariables(Collection<String> variableNames, boolean fetchAllVariables)
VariableScopeVariableScope.getVariables(Collection), but with a flag that indicates that all variables should be fetched when fetching the specific variables.
If set to false, only the specific variables will be fetched. Depending on the use case, this can be better for performance, as it avoids fetching and processing the other variables. However,
if the other variables are needed further on, getting them in one go is probably better (and the variables are cached during one Command execution).getVariables in interface VariableScopepublic void setVariables(Map<String,? extends Object> variables)
VariableScope
Variables are set according algorithm for VariableScope.setVariable(String, Object), applied separately to each variable.
setVariables in interface VariableScopevariables - a map of keys and values for the variables to be setpublic void setVariable(String variableName, Object value)
VariableScopeA variable is set according to the following algorithm:
setVariable in interface PvmExecutionsetVariable in interface VariableContainersetVariable in interface VariableScopevariableName - the name of the variable to be setvalue - the value of the variable to be setpublic void setVariable(String variableName, Object value, boolean fetchAllVariables)
VariableScopeVariableScope.setVariable(String, Object), but with an extra flag to indicate whether all variables should be fetched while doing this or not.
Variable name expression is not resolved.
The variable will be put on the highest possible scope. For an execution this is the process instance execution. If this is not wanted, use the VariableScope.setVariableLocal(String, Object) method
instead.
The default (e.g. when calling VariableScope.setVariable(String, Object)), is true, for backwards compatibility reasons. However, in some use cases, it might make sense not to fetch any other
variables when setting one variable (for example when doing nothing more than just setting one variable).setVariable in interface VariableScopepublic Object setVariableLocal(String variableName, Object value, boolean fetchAllVariables)
VariableScopeVariableScope.setVariableLocal(String, Object), but with an extra flag to indicate whether all variables should be fetched while doing this or not.setVariableLocal in interface VariableScopepublic boolean hasVariable(String variableName)
VariableScopehasVariable in interface PvmExecutionhasVariable in interface VariableContainerhasVariable in interface VariableScopeprotected void ensureVariablesInitialized()
protected String getToStringIdentity()
public boolean isProcessInstanceType()
ActivityExecutionisProcessInstanceType in interface ActivityExecutionisProcessInstanceType in interface DelegateExecutionpublic void inactivate()
ActivityExecutioninactivate in interface ActivityExecutioninactivate in interface DelegateExecutionpublic String getId()
DelegateExecutiongetId in interface DelegateExecutionpublic TransitionImpl getTransition()
getTransition in interface InterpretableExecutionpublic void setTransition(TransitionImpl transition)
setTransition in interface InterpretableExecutionpublic Integer getExecutionListenerIndex()
getExecutionListenerIndex in interface InterpretableExecutionpublic void setExecutionListenerIndex(Integer executionListenerIndex)
setExecutionListenerIndex in interface InterpretableExecutionpublic boolean isConcurrent()
ActivityExecutionisConcurrent in interface ActivityExecutionisConcurrent in interface DelegateExecutionpublic void setConcurrent(boolean isConcurrent)
ActivityExecutionsetConcurrent in interface ActivityExecutionsetConcurrent in interface DelegateExecutionpublic boolean isActive()
ActivityExecutionisActive in interface ActivityExecutionisActive in interface DelegateExecutionpublic void setActive(boolean isActive)
ActivityExecutionsetActive in interface ActivityExecutionsetActive in interface DelegateExecutionpublic boolean isEnded()
ActivityExecutionisEnded in interface ActivityExecutionisEnded in interface PvmProcessInstanceisEnded in interface DelegateExecutionpublic void setEnded(boolean ended)
ActivityExecutionActivityExecution.end() to set the boolean and execution removal methods.setEnded in interface ActivityExecutionpublic void setProcessDefinition(ProcessDefinitionImpl processDefinition)
setProcessDefinition in interface InterpretableExecutionpublic String getEventName()
DelegateExecutionExecutionListener.getEventName in interface ExecutionListenerExecutiongetEventName in interface DelegateExecutionpublic void setEventName(String eventName)
DelegateExecutionExecutionListener).setEventName in interface InterpretableExecutionsetEventName in interface DelegateExecutionpublic PvmProcessElement getEventSource()
getEventSource in interface ExecutionListenerExecutionpublic void setEventSource(PvmProcessElement eventSource)
setEventSource in interface InterpretableExecutionpublic String getDeleteReason()
getDeleteReason in interface ExecutionListenerExecutionpublic void setDeleteReason(String deleteReason)
public ExecutionImpl getReplacedBy()
getReplacedBy in interface InterpretableExecutionpublic void setReplacedBy(InterpretableExecution replacedBy)
setReplacedBy in interface InterpretableExecutionpublic void setExecutions(List<ExecutionImpl> executions)
public boolean isDeleteRoot()
isDeleteRoot in interface InterpretableExecutionpublic String getCurrentActivityId()
DelegateExecutiongetCurrentActivityId in interface DelegateExecutionpublic String getCurrentActivityName()
public Map<String,VariableInstance> getVariableInstances()
VariableScopeVariableInstance interface, which gives more information than only the value (type, execution id, etc.)getVariableInstances in interface VariableScopepublic Map<String,VariableInstance> getVariableInstances(Collection<String> variableNames)
VariableScopeVariableScope.getVariableInstances(), but limited to only the variables with the provided names.getVariableInstances in interface VariableScopepublic Map<String,VariableInstance> getVariableInstances(Collection<String> variableNames, boolean fetchAllVariables)
VariableScopeVariableScope.getVariables(Collection, boolean) but returns the variables as instances of the VariableInstance interface, which gives more information than only the value
(type, execution id, etc.)getVariableInstances in interface VariableScopepublic Map<String,VariableInstance> getVariableInstancesLocal()
VariableScopeVariableInstance interface, which provided additional information about the variable.getVariableInstancesLocal in interface VariableScopepublic Map<String,VariableInstance> getVariableInstancesLocal(Collection<String> variableNames)
VariableScopeVariableScope.getVariableInstances(Collection), but only for variables local to this scope.getVariableInstancesLocal in interface VariableScopepublic Map<String,VariableInstance> getVariableInstancesLocal(Collection<String> variableNames, boolean fetchAllVariables)
VariableScopeVariableScope.getVariableInstances(Collection, boolean), but only for variables local to this scope.getVariableInstancesLocal in interface VariableScopepublic VariableInstance getVariableInstance(String variableName)
VariableScopeVariableScope.getVariable(String), but returns a VariableInstance instance, which contains more information than just the value.getVariableInstance in interface VariableScopepublic VariableInstance getVariableInstance(String variableName, boolean fetchAllVariables)
VariableScopeVariableScope.getVariable(String, boolean), but returns an instance of VariableInstance, which has some additional information beyond the value.getVariableInstance in interface VariableScopepublic Object getVariableLocal(String variableName)
VariableScopegetVariableLocal in interface VariableScopepublic VariableInstanceEntity getVariableInstanceLocal(String variableName)
VariableScopeVariableScope.getVariableLocal(String), but returns an instance of VariableInstance, which has some additional information beyond the value.getVariableInstanceLocal in interface VariableScopepublic Object getVariableLocal(String variableName, boolean fetchAllVariables)
VariableScopeVariableScope.getVariableLocal(String), but has an extra flag that indicates whether or not all variables need to be fetched when getting one variable.
By default true (for backwards compatibility reasons), which means that calling VariableScope.getVariableLocal(String) will fetch all variables, of the current scope. Setting this flag to false can
thus be better for performance. However, variables are cached, and if other variables are used later on, setting this true might actually be better for performance.getVariableLocal in interface VariableScopepublic VariableInstanceEntity getVariableInstanceLocal(String variableName, boolean fetchAllVariables)
VariableScopeVariableScope.getVariableLocal(String, boolean), but returns an instance of VariableInstance, which has some additional information beyond the value.getVariableInstanceLocal in interface VariableScopepublic <T> T getVariable(String variableName, Class<T> variableClass)
VariableScopeVariableScope.getVariable(String) method.getVariable in interface VariableScopepublic <T> T getVariableLocal(String variableName, Class<T> variableClass)
VariableScopeVariableScope.getVariableLocal(String) method.getVariableLocal in interface VariableScopepublic Set<String> getVariableNames()
VariableScopegetVariableNames in interface VariableScopepublic Set<String> getVariableNamesLocal()
VariableScopegetVariableNamesLocal in interface VariableScopepublic Map<String,Object> getVariablesLocal()
VariableScopeVariableScope.getVariables(), the variables from the parent scope won't be returned.getVariablesLocal in interface VariableScopepublic Map<String,Object> getVariablesLocal(Collection<String> variableNames)
VariableScopeVariableScope.getVariables(Collection), but only for variables local to this scope.getVariablesLocal in interface VariableScopepublic Map<String,Object> getVariablesLocal(Collection<String> variableNames, boolean fetchAllVariables)
VariableScopeVariableScope.getVariables(Collection, boolean), but only for variables local to this scope.getVariablesLocal in interface VariableScopepublic boolean hasVariableLocal(String variableName)
VariableScopehasVariableLocal in interface VariableScopepublic boolean hasVariables()
VariableScopehasVariables in interface VariableScopepublic boolean hasVariablesLocal()
VariableScopehasVariablesLocal in interface VariableScopepublic void removeVariable(String variableName)
VariableScoperemoveVariable in interface VariableScopepublic void removeVariableLocal(String variableName)
VariableScoperemoveVariableLocal in interface VariableScopepublic void removeVariables(Collection<String> variableNames)
VariableScoperemoveVariables in interface VariableScopepublic void removeVariablesLocal(Collection<String> variableNames)
VariableScoperemoveVariablesLocal in interface VariableScopepublic void removeVariables()
VariableScoperemoveVariables in interface VariableScopepublic void removeVariablesLocal()
VariableScoperemoveVariablesLocal in interface VariableScopepublic void deleteVariablesLocal()
public Object setVariableLocal(String variableName, Object value)
VariableScopeVariableScope.setVariable(String, Object), but the variable is set to this scope specifically. Variable name
is handled as a variable name string without resolving an expression.setVariableLocal in interface VariableScopepublic void setVariablesLocal(Map<String,? extends Object> variables)
VariableScopeVariableScope.setVariables(Map), but the variable are set on this scope specifically.setVariablesLocal in interface VariableScopepublic boolean isEventScope()
isEventScope in interface InterpretableExecutionpublic void setEventScope(boolean isEventScope)
setEventScope in interface InterpretableExecutionpublic StartingExecution getStartingExecution()
getStartingExecution in interface InterpretableExecutionpublic void disposeStartingExecution()
disposeStartingExecution in interface InterpretableExecutionpublic String getTenantId()
DelegateExecutiongetTenantId in interface VariableContainergetTenantId in interface DelegateExecutionpublic boolean isMultiInstanceRoot()
DelegateExecutionisMultiInstanceRoot in interface DelegateExecutionpublic void setMultiInstanceRoot(boolean isMultiInstanceRoot)
DelegateExecutionsetMultiInstanceRoot in interface DelegateExecutionpublic String getPropagatedStageInstanceId()
DelegateExecutiongetPropagatedStageInstanceId in interface DelegateExecutionpublic void setTransientVariablesLocal(Map<String,Object> transientVariables)
VariableScopeVariableScope.setVariablesLocal(Map), but for transient variables. See VariableScope.setTransientVariable(String, Object) for the rules on 'transient' variables.setTransientVariablesLocal in interface VariableScopepublic void setTransientVariableLocal(String variableName, Object variableValue)
VariableScopeVariableScope.setVariableLocal(String, Object), but for a transient variable. See VariableScope.setTransientVariable(String, Object) for the rules on 'transient' variables.setTransientVariableLocal in interface VariableScopepublic void setTransientVariables(Map<String,Object> transientVariables)
VariableScopeVariableScope.setVariables(Map), but for transient variables. See VariableScope.setTransientVariable(String, Object) for the rules on 'transient' variables.setTransientVariables in interface VariableScopepublic void setTransientVariable(String variableName, Object variableValue)
VariableScopeVariableScope.setVariable(String, Object), but the variable is transient:
- no history is kept for the variable - the variable is only available until a waitstate is reached in the process - transient variables 'shadow' persistent variable (when getVariable('abc')
where 'abc' is both persistent and transient, the transient value is returned.setTransientVariable in interface VariableContainersetTransientVariable in interface VariableScopepublic Object getTransientVariableLocal(String variableName)
VariableScopeVariableScope.getVariableLocal(String), but for a transient variable. See VariableScope.setTransientVariable(String, Object) for the rules on 'transient' variables.getTransientVariableLocal in interface VariableScopepublic Map<String,Object> getTransientVariablesLocal()
VariableScopeVariableScope.getVariableLocal(String), but for transient variables only. See VariableScope.setTransientVariable(String, Object) for the rules on 'transient' variables.getTransientVariablesLocal in interface VariableScopepublic Object getTransientVariable(String variableName)
VariableScopeVariableScope.getVariable(String), including the searching via the parent scopes, but for transient variables only. See VariableScope.setTransientVariable(String, Object) for the rules on
'transient' variables.getTransientVariable in interface VariableScopepublic Map<String,Object> getTransientVariables()
VariableScopeVariableScope.getVariables(), but for transient variables only. See VariableScope.setTransientVariable(String, Object) for the rules on 'transient' variables.getTransientVariables in interface VariableScopepublic void removeTransientVariableLocal(String variableName)
VariableScopeVariableScope.setTransientVariable(String, Object) for the rules on 'transient' variables.removeTransientVariableLocal in interface VariableScopepublic void removeTransientVariablesLocal()
VariableScopeVariableScope.setTransientVariable(String, Object) for the rules on 'transient' variables.removeTransientVariablesLocal in interface VariableScopepublic void removeTransientVariable(String variableName)
VariableScopeVariableScope.setTransientVariable(String, Object) for the rules on 'transient' variables.removeTransientVariable in interface VariableScopepublic void removeTransientVariables()
VariableScopeVariableScope.setTransientVariable(String, Object) for the rules on 'transient' variables.removeTransientVariables in interface VariableScopeCopyright © 2023 Flowable. All rights reserved.