public class GetActivityInstanceCmd extends Object implements Command<ActivityInstance>
Creates an activity instance tree according to the following strategy:
Modifier and Type | Class and Description |
---|---|
static class |
GetActivityInstanceCmd.ExecutionIdComparator |
Modifier and Type | Field and Description |
---|---|
protected String |
processInstanceId |
Constructor and Description |
---|
GetActivityInstanceCmd(String processInstanceId) |
Modifier and Type | Method and Description |
---|---|
protected void |
checkGetActivityInstance(String processInstanceId,
CommandContext commandContext) |
protected ActivityInstanceImpl |
createActivityInstance(PvmExecutionImpl scopeExecution,
ScopeImpl scope,
String activityInstanceId,
String parentActivityInstanceId) |
protected TransitionInstanceImpl |
createTransitionInstance(PvmExecutionImpl execution) |
ActivityInstance |
execute(CommandContext commandContext) |
protected List<ExecutionEntity> |
filterLeaves(List<ExecutionEntity> executionList) |
protected List<ExecutionEntity> |
filterNonEventScopeExecutions(List<ExecutionEntity> executionList) |
protected ExecutionEntity |
filterProcessInstance(List<ExecutionEntity> executionList) |
protected void |
loadChildExecutionsFromCache(ExecutionEntity execution,
List<ExecutionEntity> childExecutions)
Loads all executions that are part of this process instance tree from the dbSqlSession cache.
|
protected List<ExecutionEntity> |
loadFromDb(String processInstanceId,
CommandContext commandContext) |
protected List<ExecutionEntity> |
loadProcessInstance(String processInstanceId,
CommandContext commandContext) |
protected void |
orderById(List<ExecutionEntity> leaves) |
protected void |
populateChildInstances(Map<String,ActivityInstanceImpl> activityInstances,
Map<String,TransitionInstanceImpl> transitionInstances) |
protected <S,T> void |
putListElement(Map<S,List<T>> mapOfLists,
S key,
T listElement) |
protected String processInstanceId
public GetActivityInstanceCmd(String processInstanceId)
public ActivityInstance execute(CommandContext commandContext)
execute
in interface Command<ActivityInstance>
protected void checkGetActivityInstance(String processInstanceId, CommandContext commandContext)
protected void orderById(List<ExecutionEntity> leaves)
protected ActivityInstanceImpl createActivityInstance(PvmExecutionImpl scopeExecution, ScopeImpl scope, String activityInstanceId, String parentActivityInstanceId)
protected TransitionInstanceImpl createTransitionInstance(PvmExecutionImpl execution)
protected void populateChildInstances(Map<String,ActivityInstanceImpl> activityInstances, Map<String,TransitionInstanceImpl> transitionInstances)
protected ExecutionEntity filterProcessInstance(List<ExecutionEntity> executionList)
protected List<ExecutionEntity> filterLeaves(List<ExecutionEntity> executionList)
protected List<ExecutionEntity> filterNonEventScopeExecutions(List<ExecutionEntity> executionList)
protected List<ExecutionEntity> loadProcessInstance(String processInstanceId, CommandContext commandContext)
protected List<ExecutionEntity> loadFromDb(String processInstanceId, CommandContext commandContext)
protected void loadChildExecutionsFromCache(ExecutionEntity execution, List<ExecutionEntity> childExecutions)
execution
- the current root execution (already contained in childExecutions)childExecutions
- the list in which all child executions should be collectedCopyright © 2018. All rights reserved.