public class ProcessExecutorImpl extends Object implements ProcessExecutor
| Modifier and Type | Field and Description |
|---|---|
protected org.bonitasoft.engine.core.process.instance.api.ActivityInstanceService |
activityInstanceService |
protected BPMInstancesCreator |
bpmInstancesCreator |
protected org.bonitasoft.engine.classloader.ClassLoaderService |
classLoaderService |
protected org.bonitasoft.engine.core.connector.ConnectorService |
connectorService |
protected EventsHandler |
eventsHandler |
protected org.bonitasoft.engine.core.expression.control.api.ExpressionResolverService |
expressionResolverService |
protected org.bonitasoft.engine.core.process.instance.api.ProcessInstanceService |
processInstanceService |
| Constructor and Description |
|---|
ProcessExecutorImpl(org.bonitasoft.engine.core.process.instance.api.ActivityInstanceService activityInstanceService,
org.bonitasoft.engine.core.process.instance.api.ProcessInstanceService processInstanceService,
org.bonitasoft.engine.log.technical.TechnicalLoggerService logger,
FlowNodeExecutor flowNodeExecutor,
org.bonitasoft.engine.work.WorkService workService,
ProcessDefinitionService processDefinitionService,
org.bonitasoft.engine.core.process.instance.api.GatewayInstanceService gatewayInstanceService,
org.bonitasoft.engine.core.process.instance.api.TransitionService transitionService,
org.bonitasoft.engine.core.process.instance.api.event.EventInstanceService eventInstanceService,
org.bonitasoft.engine.core.connector.ConnectorService connectorService,
org.bonitasoft.engine.core.connector.ConnectorInstanceService connectorInstanceService,
org.bonitasoft.engine.classloader.ClassLoaderService classLoaderService,
org.bonitasoft.engine.core.operation.OperationService operationService,
org.bonitasoft.engine.core.expression.control.api.ExpressionResolverService expressionResolverService,
org.bonitasoft.engine.events.EventService eventService,
Map<String,SProcessInstanceHandler<org.bonitasoft.engine.events.model.SEvent>> handlers,
org.bonitasoft.engine.core.process.document.api.ProcessDocumentService processDocumentService,
org.bonitasoft.engine.sessionaccessor.ReadSessionAccessor sessionAccessor,
ContainerRegistry containerRegistry,
BPMInstancesCreator bpmInstancesCreator,
org.bonitasoft.engine.core.process.instance.api.TokenService tokenService,
EventsHandler eventsHandler,
FlowNodeStateManager flowNodeStateManager) |
| Modifier and Type | Method and Description |
|---|---|
protected org.bonitasoft.engine.core.process.document.model.SProcessDocument |
attachDocument(long processInstanceId,
String documentName,
String fileName,
String mimeType,
byte[] documentContent,
long authorId) |
protected org.bonitasoft.engine.core.process.document.model.SProcessDocument |
attachDocument(long processInstanceId,
String documentName,
String fileName,
String mimeType,
String url,
long authorId) |
void |
childFinished(long processDefinitionId,
long flowNodeInstanceId,
long parentId)
Method called to notify this container executor that a child reached the given state
|
protected void |
createDocuments(SProcessDefinition sDefinition,
org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance,
long authorId) |
protected org.bonitasoft.engine.core.process.instance.model.SProcessInstance |
createProcessInstance(SProcessDefinition processDefinition,
long starterId,
long starterSubstituteId,
long callerId) |
protected Boolean |
evaluateCondition(SProcessDefinition sDefinition,
STransitionDefinition sTransitionDefinition,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext contextDependency) |
protected List<STransitionDefinition> |
evaluateOutgoingTransitions(List<STransitionDefinition> outgoingTransitionDefinitions,
SProcessDefinition sDefinition,
org.bonitasoft.engine.core.process.instance.model.SFlowNodeInstance flowNodeInstance) |
protected List<STransitionDefinition> |
evaluateTransitionsForImpliciteGateway(SProcessDefinition sDefinition,
org.bonitasoft.engine.core.process.instance.model.SFlowNodeInstance flowNodeInstance,
List<STransitionDefinition> outgoingTransitionDefinitions,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext sExpressionContext) |
boolean |
executeConnectors(SProcessDefinition processDefinition,
org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance,
ConnectorEvent activationEvent,
FlowNodeSelector selectorForConnectorOnEnter) |
protected void |
executeConnectors(SProcessDefinition processDefinition,
org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance,
List<ConnectorDefinitionWithInputValues> connectorsList) |
org.bonitasoft.engine.core.process.instance.api.states.FlowNodeState |
executeFlowNode(long flowNodeInstanceId,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext contextDependency,
List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
long processInstanceId,
Long executerId,
Long executerSubstituteId)
Execute a flow node in the context of this container executor
|
protected void |
executeOperations(List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
Map<String,Object> context,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext expressionContext,
org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance) |
protected STransitionDefinition |
getDefaultTransition(SProcessDefinition sDefinition,
org.bonitasoft.engine.core.process.instance.model.SFlowNodeInstance flowNodeInstance) |
String |
getHandledType() |
protected void |
handleEventSubProcess(SProcessDefinition sProcessDefinition,
org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance,
long subProcessDefinitionId) |
void |
handleProcessCompletion(SProcessDefinition sProcessDefinition,
org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance,
boolean hasActionsToExecute) |
protected boolean |
initialize(long userId,
SProcessDefinition sProcessDefinition,
org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext expressionContext,
List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
Map<String,Object> context,
SFlowElementContainerDefinition processContainer,
List<ConnectorDefinitionWithInputValues> connectors,
FlowNodeSelector selectorForConnectorOnEnter) |
org.bonitasoft.engine.core.process.instance.model.SProcessInstance |
start(long starterId,
long starterSubstituteId,
List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
Map<String,Object> context,
List<ConnectorDefinitionWithInputValues> connectorsWithInput,
FlowNodeSelector selector) |
org.bonitasoft.engine.core.process.instance.model.SProcessInstance |
start(long processDefinitionId,
long targetSFlowNodeDefinitionId,
long starterId,
long starterSubstituteId,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext expressionContext,
List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
Map<String,Object> context,
List<ConnectorDefinitionWithInputValues> connectorsWithInput,
long callerId,
long subProcessDefinitionId) |
org.bonitasoft.engine.core.process.instance.model.SProcessInstance |
start(long starterId,
long starterSubstituteId,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext expressionContext,
List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
Map<String,Object> context,
List<ConnectorDefinitionWithInputValues> connectors,
long callerId,
FlowNodeSelector selector) |
org.bonitasoft.engine.core.process.instance.model.SProcessInstance |
startElements(org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance,
FlowNodeSelector selector) |
protected final org.bonitasoft.engine.core.process.instance.api.ActivityInstanceService activityInstanceService
protected final org.bonitasoft.engine.core.process.instance.api.ProcessInstanceService processInstanceService
protected final org.bonitasoft.engine.classloader.ClassLoaderService classLoaderService
protected final org.bonitasoft.engine.core.expression.control.api.ExpressionResolverService expressionResolverService
protected final org.bonitasoft.engine.core.connector.ConnectorService connectorService
protected final BPMInstancesCreator bpmInstancesCreator
protected final EventsHandler eventsHandler
public ProcessExecutorImpl(org.bonitasoft.engine.core.process.instance.api.ActivityInstanceService activityInstanceService,
org.bonitasoft.engine.core.process.instance.api.ProcessInstanceService processInstanceService,
org.bonitasoft.engine.log.technical.TechnicalLoggerService logger,
FlowNodeExecutor flowNodeExecutor,
org.bonitasoft.engine.work.WorkService workService,
ProcessDefinitionService processDefinitionService,
org.bonitasoft.engine.core.process.instance.api.GatewayInstanceService gatewayInstanceService,
org.bonitasoft.engine.core.process.instance.api.TransitionService transitionService,
org.bonitasoft.engine.core.process.instance.api.event.EventInstanceService eventInstanceService,
org.bonitasoft.engine.core.connector.ConnectorService connectorService,
org.bonitasoft.engine.core.connector.ConnectorInstanceService connectorInstanceService,
org.bonitasoft.engine.classloader.ClassLoaderService classLoaderService,
org.bonitasoft.engine.core.operation.OperationService operationService,
org.bonitasoft.engine.core.expression.control.api.ExpressionResolverService expressionResolverService,
org.bonitasoft.engine.events.EventService eventService,
Map<String,SProcessInstanceHandler<org.bonitasoft.engine.events.model.SEvent>> handlers,
org.bonitasoft.engine.core.process.document.api.ProcessDocumentService processDocumentService,
org.bonitasoft.engine.sessionaccessor.ReadSessionAccessor sessionAccessor,
ContainerRegistry containerRegistry,
BPMInstancesCreator bpmInstancesCreator,
org.bonitasoft.engine.core.process.instance.api.TokenService tokenService,
EventsHandler eventsHandler,
FlowNodeStateManager flowNodeStateManager)
public org.bonitasoft.engine.core.process.instance.api.states.FlowNodeState executeFlowNode(long flowNodeInstanceId,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext contextDependency,
List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
long processInstanceId,
Long executerId,
Long executerSubstituteId)
throws org.bonitasoft.engine.core.process.instance.api.exceptions.SFlowNodeExecutionException
ContainerExecutorexecuteFlowNode in interface ContainerExecutorflowNodeInstanceId - The identifier of the flow node instanceprocessInstanceId - The identifier of the process instanceexecuterId - The identifier of the user which execute the flow nodeexecuterSubstituteId - The identifier of the delegated user which execute the flow nodeorg.bonitasoft.engine.core.process.instance.api.exceptions.SFlowNodeExecutionException - Throw if there is an error when execute the flow nodeprotected List<STransitionDefinition> evaluateOutgoingTransitions(List<STransitionDefinition> outgoingTransitionDefinitions, SProcessDefinition sDefinition, org.bonitasoft.engine.core.process.instance.model.SFlowNodeInstance flowNodeInstance) throws org.bonitasoft.engine.commons.exceptions.SBonitaException
org.bonitasoft.engine.commons.exceptions.SBonitaExceptionprotected List<STransitionDefinition> evaluateTransitionsForImpliciteGateway(SProcessDefinition sDefinition, org.bonitasoft.engine.core.process.instance.model.SFlowNodeInstance flowNodeInstance, List<STransitionDefinition> outgoingTransitionDefinitions, org.bonitasoft.engine.core.expression.control.model.SExpressionContext sExpressionContext) throws org.bonitasoft.engine.commons.exceptions.SBonitaException
org.bonitasoft.engine.commons.exceptions.SBonitaExceptionprotected STransitionDefinition getDefaultTransition(SProcessDefinition sDefinition, org.bonitasoft.engine.core.process.instance.model.SFlowNodeInstance flowNodeInstance)
protected Boolean evaluateCondition(SProcessDefinition sDefinition, STransitionDefinition sTransitionDefinition, org.bonitasoft.engine.core.expression.control.model.SExpressionContext contextDependency) throws org.bonitasoft.engine.expression.exception.SExpressionEvaluationException, org.bonitasoft.engine.expression.exception.SExpressionTypeUnknownException, org.bonitasoft.engine.expression.exception.SExpressionDependencyMissingException, org.bonitasoft.engine.expression.exception.SInvalidExpressionException
org.bonitasoft.engine.expression.exception.SExpressionEvaluationExceptionorg.bonitasoft.engine.expression.exception.SExpressionTypeUnknownExceptionorg.bonitasoft.engine.expression.exception.SExpressionDependencyMissingExceptionorg.bonitasoft.engine.expression.exception.SInvalidExpressionExceptionpublic boolean executeConnectors(SProcessDefinition processDefinition, org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance, ConnectorEvent activationEvent, FlowNodeSelector selectorForConnectorOnEnter) throws org.bonitasoft.engine.commons.exceptions.SBonitaException
executeConnectors in interface ProcessExecutororg.bonitasoft.engine.commons.exceptions.SBonitaExceptionprotected org.bonitasoft.engine.core.process.instance.model.SProcessInstance createProcessInstance(SProcessDefinition processDefinition, long starterId, long starterSubstituteId, long callerId) throws org.bonitasoft.engine.core.process.instance.api.exceptions.SProcessInstanceCreationException
org.bonitasoft.engine.core.process.instance.api.exceptions.SProcessInstanceCreationExceptionprotected void executeOperations(List<org.bonitasoft.engine.core.operation.model.SOperation> operations, Map<String,Object> context, org.bonitasoft.engine.core.expression.control.model.SExpressionContext expressionContext, org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance) throws org.bonitasoft.engine.commons.exceptions.SBonitaException
org.bonitasoft.engine.commons.exceptions.SBonitaExceptionprotected boolean initialize(long userId,
SProcessDefinition sProcessDefinition,
org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext expressionContext,
List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
Map<String,Object> context,
SFlowElementContainerDefinition processContainer,
List<ConnectorDefinitionWithInputValues> connectors,
FlowNodeSelector selectorForConnectorOnEnter)
throws BonitaHomeNotSetException,
IOException,
InvalidEvaluationConnectorConditionException,
org.bonitasoft.engine.commons.exceptions.SBonitaException
BonitaHomeNotSetExceptionIOExceptionInvalidEvaluationConnectorConditionExceptionorg.bonitasoft.engine.commons.exceptions.SBonitaExceptionprotected void createDocuments(SProcessDefinition sDefinition, org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance, long authorId) throws org.bonitasoft.engine.core.process.document.api.SProcessDocumentCreationException, BonitaHomeNotSetException, org.bonitasoft.engine.sessionaccessor.STenantIdNotSetException, IOException
org.bonitasoft.engine.core.process.document.api.SProcessDocumentCreationExceptionBonitaHomeNotSetExceptionorg.bonitasoft.engine.sessionaccessor.STenantIdNotSetExceptionIOExceptionprotected org.bonitasoft.engine.core.process.document.model.SProcessDocument attachDocument(long processInstanceId,
String documentName,
String fileName,
String mimeType,
String url,
long authorId)
throws org.bonitasoft.engine.core.process.document.api.SProcessDocumentCreationException
org.bonitasoft.engine.core.process.document.api.SProcessDocumentCreationExceptionprotected org.bonitasoft.engine.core.process.document.model.SProcessDocument attachDocument(long processInstanceId,
String documentName,
String fileName,
String mimeType,
byte[] documentContent,
long authorId)
throws org.bonitasoft.engine.core.process.document.api.SProcessDocumentCreationException
org.bonitasoft.engine.core.process.document.api.SProcessDocumentCreationExceptionpublic void childFinished(long processDefinitionId,
long flowNodeInstanceId,
long parentId)
throws org.bonitasoft.engine.commons.exceptions.SBonitaException
ContainerExecutorchildFinished in interface ContainerExecutorprocessDefinitionId - The identifier of the process definitionflowNodeInstanceId - The identifier of the flow node instanceparentId - The identifier of the parent of the flow nodeorg.bonitasoft.engine.commons.exceptions.SBonitaExceptionpublic void handleProcessCompletion(SProcessDefinition sProcessDefinition, org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance, boolean hasActionsToExecute) throws org.bonitasoft.engine.commons.exceptions.SBonitaException
handleProcessCompletion in interface ProcessExecutororg.bonitasoft.engine.commons.exceptions.SBonitaExceptionpublic org.bonitasoft.engine.core.process.instance.model.SProcessInstance start(long starterId,
long starterSubstituteId,
List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
Map<String,Object> context,
List<ConnectorDefinitionWithInputValues> connectorsWithInput,
FlowNodeSelector selector)
throws org.bonitasoft.engine.core.process.instance.api.exceptions.SProcessInstanceCreationException
start in interface ProcessExecutororg.bonitasoft.engine.core.process.instance.api.exceptions.SProcessInstanceCreationExceptionpublic org.bonitasoft.engine.core.process.instance.model.SProcessInstance start(long processDefinitionId,
long targetSFlowNodeDefinitionId,
long starterId,
long starterSubstituteId,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext expressionContext,
List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
Map<String,Object> context,
List<ConnectorDefinitionWithInputValues> connectorsWithInput,
long callerId,
long subProcessDefinitionId)
throws org.bonitasoft.engine.core.process.instance.api.exceptions.SProcessInstanceCreationException
start in interface ProcessExecutororg.bonitasoft.engine.core.process.instance.api.exceptions.SProcessInstanceCreationExceptionpublic org.bonitasoft.engine.core.process.instance.model.SProcessInstance start(long starterId,
long starterSubstituteId,
org.bonitasoft.engine.core.expression.control.model.SExpressionContext expressionContext,
List<org.bonitasoft.engine.core.operation.model.SOperation> operations,
Map<String,Object> context,
List<ConnectorDefinitionWithInputValues> connectors,
long callerId,
FlowNodeSelector selector)
throws org.bonitasoft.engine.core.process.instance.api.exceptions.SProcessInstanceCreationException
start in interface ProcessExecutororg.bonitasoft.engine.core.process.instance.api.exceptions.SProcessInstanceCreationExceptionprotected void executeConnectors(SProcessDefinition processDefinition, org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance, List<ConnectorDefinitionWithInputValues> connectorsList) throws InvalidEvaluationConnectorConditionException, org.bonitasoft.engine.core.connector.exception.SConnectorException
InvalidEvaluationConnectorConditionExceptionorg.bonitasoft.engine.core.connector.exception.SConnectorExceptionprotected void handleEventSubProcess(SProcessDefinition sProcessDefinition, org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance, long subProcessDefinitionId) throws org.bonitasoft.engine.commons.exceptions.SBonitaException
org.bonitasoft.engine.commons.exceptions.SBonitaExceptionpublic org.bonitasoft.engine.core.process.instance.model.SProcessInstance startElements(org.bonitasoft.engine.core.process.instance.model.SProcessInstance sProcessInstance,
FlowNodeSelector selector)
throws org.bonitasoft.engine.core.process.instance.api.exceptions.SProcessInstanceCreationException,
org.bonitasoft.engine.core.process.instance.api.exceptions.SFlowNodeExecutionException
startElements in interface ProcessExecutororg.bonitasoft.engine.core.process.instance.api.exceptions.SProcessInstanceCreationExceptionorg.bonitasoft.engine.core.process.instance.api.exceptions.SFlowNodeExecutionExceptionpublic String getHandledType()
getHandledType in interface ContainerExecutorCopyright © 2014 Bonitasoft S.A.. All rights reserved.