Package org.camunda.bpm.engine.cdi
Class CurrentProcessInstance
- java.lang.Object
- 
- org.camunda.bpm.engine.cdi.CurrentProcessInstance
 
- 
 public class CurrentProcessInstance extends java.lang.ObjectAllows to access executions and tasks of a managed process instance via dependency injection. A process instance can be managed, using theBusinessProcess-bean. The producer methods provided by this class have been extracted from theBusinessProcess-bean in order to allow for specializing it.- Author:
- Falko Menge
 
- 
- 
Constructor SummaryConstructors Constructor Description CurrentProcessInstance()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description ExecutiongetExecution()Returns the currently associated execution or 'null'java.lang.StringgetExecutionId()ProcessInstancegetProcessInstance()Returns theProcessInstancecurrently associated or 'null'java.lang.StringgetProcessInstanceId()Returns the id of the currently associated process instance or 'null'TaskgetTask()Returns the currently associatedTaskor 'null'java.lang.StringgetTaskId()Returns the id of the task associated with the current conversation or 'null'.
 
- 
- 
- 
Method Detail- 
getProcessInstance@Produces @Named @Typed(ProcessInstance.class) public ProcessInstance getProcessInstance() Returns theProcessInstancecurrently associated or 'null'- Throws:
- ProcessEngineCdiException- if no- Executionis associated. Use- BusinessProcess.isAssociated()to check whether an association exists.
 
 - 
getProcessInstanceId@Produces @Named public java.lang.String getProcessInstanceId() Returns the id of the currently associated process instance or 'null'
 - 
getExecution@Produces @Named public Execution getExecution() Returns the currently associated execution or 'null'
 - 
getExecutionId@Produces @Named public java.lang.String getExecutionId() - See Also:
- BusinessProcess.getExecution()
 
 - 
getTask@Produces @Named public Task getTask() Returns the currently associatedTaskor 'null'- Throws:
- ProcessEngineCdiException- if no- Taskis associated. Use- BusinessProcess.isTaskAssociated()to check whether an association exists.
 
 - 
getTaskId@Produces @Named public java.lang.String getTaskId() Returns the id of the task associated with the current conversation or 'null'.
 
- 
 
-