org.jbpm.api.client
Interface ClientExecution

All Superinterfaces:
Discussable, Execution, OpenExecution, java.io.Serializable
All Known Subinterfaces:
ClientProcessInstance

public interface ClientExecution
extends OpenExecution

view upon an path of execution exposed to external clients.

Author:
Tom Baeyens

Field Summary
 
Fields inherited from interface org.jbpm.api.Execution
STATE_ACTIVE_CONCURRENT, STATE_ACTIVE_ROOT, STATE_ASYNC, STATE_CREATED, STATE_ENDED, STATE_INACTIVE_CONCURRENT_ROOT, STATE_INACTIVE_JOIN, STATE_INACTIVE_SCOPE, STATE_SUSPENDED
 
Method Summary
 void end()
          ends this execution and all of its child executions.
 void end(java.lang.String state)
          ends this execution and all it's child executions with a user defined status.
 void resume()
          resumes an execution.
 void signal()
          feeds a external trigger into this execution.
 void signal(Execution execution)
          feeds a external trigger into the given execution.
 void signal(java.util.Map<java.lang.String,?> parameters)
          feeds an external trigger into the execution with parameters.
 void signal(java.util.Map<java.lang.String,?> parameters, Execution execution)
          feeds an external trigger into a given execution with parameters.
 void signal(java.lang.String signalName)
          feeds a named external trigger into the execution.
 void signal(java.lang.String signalName, Execution execution)
          feeds a named external trigger into a given execution.
 void signal(java.lang.String signalName, java.util.Map<java.lang.String,?> parameters)
          feeds a named external trigger into the execution with parameters.
 void signal(java.lang.String signalName, java.util.Map<java.lang.String,?> parameters, Execution execution)
          feeds a named external trigger into a given execution with parameters.
 void suspend()
          suspends this execution and all it's child executions.
 
Methods inherited from interface org.jbpm.api.model.OpenExecution
createVariable, createVariable, findActiveExecutionIn, getExecution, getParent, getProcessDefinition, getProcessInstance, getSubProcessInstance, getVariable, getVariableKeys, getVariables, hasVariable, hasVariables, removeVariable, removeVariables, setPriority, setState, setVariable, setVariables
 
Methods inherited from interface org.jbpm.api.Execution
findActiveActivityNames, getExecutions, getExecutionsMap, getId, getKey, getName, getPriority, getProcessDefinitionId, getState, hasExecution, isActive, isEnded, isProcessInstance, isSuspended
 
Methods inherited from interface org.jbpm.api.model.Discussable
createComment, getComments, removeComment
 

Method Detail

end

void end()
ends this execution and all of its child executions.

All child executions will be ended and removed. This execution will not be removed from its parent.

This method should not be called in ActivityBehaviours. It can be called from outside the process execution and in ExternalActivityBehaviours.


end

void end(java.lang.String state)
ends this execution and all it's child executions with a user defined status.


signal

void signal()
feeds a external trigger into this execution.

Typically a signal causes the execution to proceed, but that doesn't necessarily has to be the case . The ExternalActivityBehaviour is responsible for interpreting the signal and acting upon it.

A signal can optionally be given a signal name, a map of parameters or both.

Since it's an external trigger, this method requires that this execution is waiting for an external trigger. So this method must be called as an external client and can not be called while this execution is executing. In an ActivityBehaviour for example you're not allowed to call the signal on the execution cause it is executing. But you are allowed to invoke this method on any other execution (at least, if that one is waiting for an external trigger).

Typically a signal will cause the execution to start executing, but that is not a must. What happens with this signal is defined in the ExternalActivityBehaviour#signal(Execution, String, Map) of the current activity.

See Also:
signal(String)

signal

void signal(java.lang.String signalName)
feeds a named external trigger into the execution.

In each state, a number of things can happen. The signal parameter specifies which of these things is happening. It's somewhat similar to a method name in the invocation of an object.

See Also:
See the unnamed signal for more information

signal

void signal(java.util.Map<java.lang.String,?> parameters)
feeds an external trigger into the execution with parameters.

See Also:
See the unnamed signal for more information

signal

void signal(java.lang.String signalName,
            java.util.Map<java.lang.String,?> parameters)
feeds a named external trigger into the execution with parameters.

In each state, a number of things can happen. The signal parameter specifies which of these things is happening. It's somewhat similar to a method name in the invocation of an object.

The parameters parameter provide extra information to the signal. Typically, the parameters are set as variables but the process language can overwrite that behaviour in the current activity. See ExternalActivityBehaviour#signal(Execution, String, Map) for more information.

See Also:
See the unnamed signal for more information

signal

void signal(Execution execution)
feeds a external trigger into the given execution.

Typically a signal causes the execution to proceed, but that doesn't necessarily has to be the case . The ExternalActivityBehaviour is responsible for interpreting the signal and acting upon it.

A signal can optionally be given a signal name, a map of parameters or both.

Since it's an external trigger, this method requires that this execution is waiting for an external trigger. So this method must be called as an external client and can not be called while this execution is executing. In an ActivityBehaviour for example you're not allowed to call the signal on the execution cause it is executing. But you are allowed to invoke this method on any other execution (at least, if that one is waiting for an external trigger).

Typically a signal will cause the execution to start executing, but that is not a must. What happens with this signal is defined in the ExternalActivityBehaviour#signal(Execution, String, Map) of the current activity.

See Also:
signal(String)

signal

void signal(java.lang.String signalName,
            Execution execution)
feeds a named external trigger into a given execution.

In each state, a number of things can happen. The signal parameter specifies which of these things is happening. It's somewhat similar to a method name in the invocation of an object.

See Also:
See the unnamed signal for more information

signal

void signal(java.util.Map<java.lang.String,?> parameters,
            Execution execution)
feeds an external trigger into a given execution with parameters.

See Also:
See the unnamed signal for more information

signal

void signal(java.lang.String signalName,
            java.util.Map<java.lang.String,?> parameters,
            Execution execution)
feeds a named external trigger into a given execution with parameters.

In each state, a number of things can happen. The signal parameter specifies which of these things is happening. It's somewhat similar to a method name in the invocation of an object.

The parameters parameter provide extra information to the signal. Typically, the parameters are set as variables but the process language can overwrite that behaviour in the current activity. See ExternalActivityBehaviour#signal(Execution, String, Map) for more information.

See Also:
See the unnamed signal for more information

suspend

void suspend()
suspends this execution and all it's child executions. Human tasks of a suspended execution shouldn't show up in people's task list and timers of suspended executions shouldn't fire.

Throws:
JbpmException - if this execution is already suspended.

resume

void resume()
resumes an execution. Inverse of suspend().

Throws:
JbpmException - if this execution is not suspended.


Copyright © 2009 JBoss, a division of Red Hat. All Rights Reserved.