|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.seam.core.AbstractMutable org.jboss.seam.core.BusinessProcess
@Scope(value=CONVERSATION) @Name(value="org.jboss.seam.core.businessProcess") @Intercept(value=NEVER) @Install(dependencies="org.jboss.seam.core.jbpm", precedence=0) public class BusinessProcess
Holds the task and process ids for the current conversation, and provides programmatic control over the business process.
Constructor Summary | |
---|---|
BusinessProcess()
|
Method Summary | |
---|---|
void |
createProcess(String processDefinitionName)
Create a process instance and associate it with the current conversation. |
void |
endTask(String transitionName)
End the current task, via the given transition. |
Long |
getProcessId()
The jBPM process instance id associated with the current conversation. |
Long |
getTaskId()
The jBPM task instance id associated with the current conversation. |
boolean |
hasActiveProcess()
Is there a process instance that has not ended associated with the current conversation? |
boolean |
hasCurrentProcess()
Is there a process instance associated with the current conversation? |
boolean |
hasCurrentTask()
Is there a task instance associated with the current conversation? |
static BusinessProcess |
instance()
|
protected void |
processEnded(Long processId)
|
protected void |
processNotFound(Long processId)
|
boolean |
resumeProcess(Long processId)
Associate the process instance with the given id with the current conversation. |
boolean |
resumeTask(Long taskId)
Associate the task instance with the given id with the current conversation. |
void |
setProcessId(Long processId)
Set the process instance id, without validating that the process instance actually exists. |
void |
setTaskId(Long taskId)
Set the task instance id, without validating that the task instance actually exists. |
void |
startTask()
Start the current task, using the current actor id |
protected void |
taskEnded(Long taskId)
|
protected void |
taskNotFound(Long taskId)
|
String |
toString()
|
void |
transition(String transitionName)
Signal the given transition for the current process instance. |
boolean |
validateTask()
Check that the task currently associated with the conversation exists and has not ended. |
Methods inherited from class org.jboss.seam.core.AbstractMutable |
---|
clearDirty, setDirty, setDirty |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public BusinessProcess()
Method Detail |
---|
public static BusinessProcess instance()
public boolean hasCurrentProcess()
public boolean hasActiveProcess()
public boolean hasCurrentTask()
public Long getProcessId()
public void setProcessId(Long processId)
public Long getTaskId()
public void setTaskId(Long taskId)
public void createProcess(String processDefinitionName)
processDefinitionName
- the jBPM process definition namepublic void startTask()
Actor
public void endTask(String transitionName)
transitionName
- the jBPM transition name, or nullpublic void transition(String transitionName)
transitionName
- the jBPM transition namepublic boolean resumeTask(Long taskId)
taskId
- the jBPM task instance id
public boolean resumeProcess(Long processId)
processId
- the jBPM process instance id
public boolean validateTask()
protected void taskNotFound(Long taskId)
protected void taskEnded(Long taskId)
protected void processEnded(Long processId)
protected void processNotFound(Long processId)
public String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |