public interface ProcessService
| Modifier and Type | Method and Description |
|---|---|
void |
abortProcessInstance(Long processInstanceId)
Aborts the specified process
|
void |
abortProcessInstances(List<Long> processInstanceIds)
Aborts all specified processes
|
void |
abortWorkItem(Long id)
Abort the specified workItem
|
void |
completeWorkItem(Long id,
Map<String,Object> results)
Completes the specified WorkItem with the given results
|
<T> T |
execute(String deploymentId,
org.kie.api.command.Command<T> command)
Executes provided command on the underlying command executor (usually KieSession)
|
<T> T |
execute(String deploymentId,
org.kie.api.runtime.manager.Context<?> context,
org.kie.api.command.Command<T> command)
Executes provided command on the underlying command executor (usually KieSession)
|
Collection<String> |
getAvailableSignals(Long processInstanceId)
Returns all signals available in current state of given process instance
|
org.kie.api.runtime.process.ProcessInstance |
getProcessInstance(org.kie.internal.process.CorrelationKey correlationKey)
Returns process instance information.
|
org.kie.api.runtime.process.ProcessInstance |
getProcessInstance(Long processInstanceId)
Returns process instance information.
|
Object |
getProcessInstanceVariable(Long processInstanceId,
String variableName)
Gets a process instance's variable.
|
Map<String,Object> |
getProcessInstanceVariables(Long processInstanceId)
Gets a process instance's variable values.
|
org.kie.api.runtime.process.WorkItem |
getWorkItem(Long id)
Returns the specified workItem
|
List<org.kie.api.runtime.process.WorkItem> |
getWorkItemByProcessInstance(Long processInstanceId)
Returns active work items by process instance id.
|
void |
setProcessVariable(Long processInstanceId,
String variableId,
Object value)
Sets a process variable.
|
void |
setProcessVariables(Long processInstanceId,
Map<String,Object> variables)
Sets process variables.
|
void |
signalEvent(String deployment,
String signalName,
Object event)
Signal an event to a any process instance that listens to give signal that belongs to given deployment
|
void |
signalProcessInstance(Long processInstanceId,
String signalName,
Object event)
Signal an event to a single process instance
|
void |
signalProcessInstances(List<Long> processInstanceIds,
String signalName,
Object event)
Signal an event to given list of process instances
|
Long |
startProcess(String deploymentId,
String processId)
Starts a process with no variables
|
Long |
startProcess(String deploymentId,
String processId,
org.kie.internal.process.CorrelationKey correlationKey)
Starts a process with no variables
|
Long |
startProcess(String deploymentId,
String processId,
org.kie.internal.process.CorrelationKey correlationKey,
Map<String,Object> params)
Starts a process with no variables
|
Long |
startProcess(String deploymentId,
String processId,
Map<String,Object> params)
Starts a process with no variables
|
Long startProcess(String deploymentId, String processId)
deploymentId - deployment information for the process's kjarprocessId - The process's identifierRuntimeException - in case of encountered errorsDeploymentNotFoundException - in case deployment with given deployment id does not exist or is not activeLong startProcess(String deploymentId, String processId, Map<String,Object> params)
deploymentId - deployment information for the process's kjarprocessId - The process's identifierparams - process variablesRuntimeException - in case of encountered errorsDeploymentNotFoundException - in case deployment with given deployment id does not exist or is not activeLong startProcess(String deploymentId, String processId, org.kie.internal.process.CorrelationKey correlationKey)
deploymentId - deployment information for the process's kjarprocessId - The process's identifiercorrelationKey - correlation key to be assigned to process instance - must be uniqueRuntimeException - in case of encountered errorsDeploymentNotFoundException - in case deployment with given deployment id does not exist or is not activeLong startProcess(String deploymentId, String processId, org.kie.internal.process.CorrelationKey correlationKey, Map<String,Object> params)
deploymentId - deployment information for the process's kjarprocessId - The process's identifiercorrelationKey - correlation key to be assigned to process instance - must be uniqueparams - process variablesRuntimeException - in case of encountered errorsDeploymentNotFoundException - in case deployment with given deployment id does not exist or is not activevoid abortProcessInstance(Long processInstanceId)
processInstanceId - process instance's unique identifierDeploymentNotFoundException - in case deployment unit was not foundProcessInstanceNotFoundException - in case process instance with given id was not foundvoid abortProcessInstances(List<Long> processInstanceIds)
processInstanceIds - list of process instance unique identifiersDeploymentNotFoundException - in case deployment unit was not foundProcessInstanceNotFoundException - in case process instance with given id was not foundvoid signalProcessInstance(Long processInstanceId, String signalName, Object event)
processInstanceId - the process instance's unique identifiersignalName - the signal's id in the processevent - the event object to be passed in with the eventDeploymentNotFoundException - in case deployment unit was not foundProcessInstanceNotFoundException - in case process instance with given id was not foundvoid signalProcessInstances(List<Long> processInstanceIds, String signalName, Object event)
processInstanceIds - list of process instance unique identifierssignalName - the signal's id in the processevent - the event object to be passed in with the eventDeploymentNotFoundException - in case deployment unit was not foundProcessInstanceNotFoundException - in case process instance with given id was not foundvoid signalEvent(String deployment, String signalName, Object event)
deployment - information for the process's kjarsignalName - the signal's id in the processevent - the event object to be passed in with the eventDeploymentNotFoundException - in case deployment unit was not foundorg.kie.api.runtime.process.ProcessInstance getProcessInstance(Long processInstanceId)
processInstanceId - The process instance's unique identifierDeploymentNotFoundException - in case deployment unit was not foundorg.kie.api.runtime.process.ProcessInstance getProcessInstance(org.kie.internal.process.CorrelationKey correlationKey)
correlationKey - correlation key assigned to process instanceDeploymentNotFoundException - in case deployment unit was not foundvoid setProcessVariable(Long processInstanceId, String variableId, Object value)
processInstanceId - The process instance's unique identifier.variableName - The variable name to set.variable - The variable value.DeploymentNotFoundException - in case deployment unit was not foundProcessInstanceNotFoundException - in case process instance with given id was not foundvoid setProcessVariables(Long processInstanceId, Map<String,Object> variables)
processInstanceId - The process instance's unique identifier.variables - map of process variables (key - variable name, value - variable value)DeploymentNotFoundException - in case deployment unit was not foundProcessInstanceNotFoundException - in case process instance with given id was not foundObject getProcessInstanceVariable(Long processInstanceId, String variableName)
processInstanceId - the process instance's unique identifier.variableName - the variable name to get from the process.DeploymentNotFoundException - in case deployment unit was not foundProcessInstanceNotFoundException - in case process instance with given id was not foundMap<String,Object> getProcessInstanceVariables(Long processInstanceId)
processInstanceId - The process instance's unique identifier.DeploymentNotFoundException - in case deployment unit was not foundProcessInstanceNotFoundException - in case process instance with given id was not foundCollection<String> getAvailableSignals(Long processInstanceId)
processInstanceId - process instance idvoid completeWorkItem(Long id, Map<String,Object> results)
id - workItem idresults - results of the workItemDeploymentNotFoundException - in case deployment unit was not foundWorkItemNotFoundException - in case work item with given id was not foundvoid abortWorkItem(Long id)
id - workItem idDeploymentNotFoundException - in case deployment unit was not foundWorkItemNotFoundException - in case work item with given id was not foundorg.kie.api.runtime.process.WorkItem getWorkItem(Long id)
id - workItem idDeploymentNotFoundException - in case deployment unit was not foundWorkItemNotFoundException - in case work item with given id was not foundList<org.kie.api.runtime.process.WorkItem> getWorkItemByProcessInstance(Long processInstanceId)
processInstanceId - process instance idDeploymentNotFoundException - in case deployment unit was not foundProcessInstanceNotFoundException - in case process instance with given id was not found<T> T execute(String deploymentId, org.kie.api.command.Command<T> command)
deploymentId - deployment information for the process's kjarcommand - actual command for executionDeploymentNotFoundException - in case deployment with given deployment id does not exist
or is not active for restricted commands (e.g. start process)<T> T execute(String deploymentId, org.kie.api.runtime.manager.Context<?> context, org.kie.api.command.Command<T> command)
deploymentId - deployment information for the process's kjarcontext - context implementation to be used to get runtime enginecommand - actual command for executionDeploymentNotFoundException - in case deployment with given deployment id does not exist
or is not active for restricted commands (e.g. start process)Copyright © 2001–2015 JBoss by Red Hat. All rights reserved.