|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jbpm.module.exe.ModuleInstance org.jbpm.context.exe.ContextInstance
maintains all the key-variable pairs for a process instance. You can obtain a ContextInstance from a processInstance from a process instance like this :
ProcessInstance processInstance = ...; ContextInstance contextInstance = processInstance.getContextInstance();More information on context and process variables can be found in the userguide, section context
Field Summary | |
protected java.util.Map |
tokenVariableMaps
|
protected java.util.Map |
transientVariables
|
Fields inherited from class org.jbpm.module.exe.ModuleInstance |
processInstance |
Constructor Summary | |
ContextInstance()
|
Method Summary | |
void |
addVariables(java.util.Map variables)
adds all the variables on the root-token (= process-instance scope). |
void |
addVariables(java.util.Map variables,
Token token)
adds all the variables to the scope of the given token. |
void |
createVariable(java.lang.String name,
java.lang.Object value)
creates a variable on the root-token (= process-instance scope) and calculates the actual VariableInstance-type from the value. |
void |
createVariable(java.lang.String name,
java.lang.Object value,
Token token)
creates a variable in the scope of the given token and calculates the actual VariableInstance-type from the value. |
void |
deleteTransientVariable(java.lang.String name)
removes the transient variable. |
void |
deleteVariable(java.lang.String name)
deletes the given variable on the root-token (=process-instance scope). |
void |
deleteVariable(java.lang.String name,
Token token)
deletes a variable from the given token. |
java.lang.Object |
getLocalVariable(java.lang.String name,
Token token)
retrieves a variable which is local to the token. |
java.lang.Object |
getTransientVariable(java.lang.String name)
retrieves the transient variable for the given name. |
java.util.Map |
getTransientVariables()
retrieves all the transient variables map. |
java.lang.Object |
getVariable(java.lang.String name)
gets the variable with the given name on the root-token (= process-instance scope). |
java.lang.Object |
getVariable(java.lang.String name,
Token token)
retrieves a variable in the scope of the token. |
java.util.Map |
getVariables()
gets all the variables on the root-token (= process-instance scope). |
java.util.Map |
getVariables(Token token)
retrieves all the variables in scope of the given token. |
boolean |
hasTransientVariable(java.lang.String name)
tells if a transient variable with the given name is present. |
boolean |
hasVariable(java.lang.String name)
checks if a variable is present with the given name on the root-token (= process-instance scope). |
boolean |
hasVariable(java.lang.String name,
Token token)
checks if a variable is present with the given name in the scope of the token. |
void |
setTransientVariable(java.lang.String name,
java.lang.Object value)
sets the transient variable for the given name to the given value. |
void |
setTransientVariables(java.util.Map transientVariables)
replaces the transient variables with the given map. |
void |
setVariable(java.lang.String name,
java.lang.Object value)
sets a variable on the process instance scope. |
void |
setVariable(java.lang.String name,
java.lang.Object value,
Token token)
sets a variable. |
Methods inherited from class org.jbpm.module.exe.ModuleInstance |
getId, getProcessInstance, setProcessInstance |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected java.util.Map tokenVariableMaps
protected transient java.util.Map transientVariables
Constructor Detail |
public ContextInstance()
Method Detail |
public void createVariable(java.lang.String name, java.lang.Object value)
public void createVariable(java.lang.String name, java.lang.Object value, Token token)
public java.util.Map getVariables()
public java.util.Map getVariables(Token token)
public void addVariables(java.util.Map variables)
public void addVariables(java.util.Map variables, Token token)
public java.lang.Object getVariable(java.lang.String name)
public java.lang.Object getVariable(java.lang.String name, Token token)
public java.lang.Object getLocalVariable(java.lang.String name, Token token)
public void setVariable(java.lang.String name, java.lang.Object value)
public void setVariable(java.lang.String name, java.lang.Object value, Token token)
public boolean hasVariable(java.lang.String name)
public boolean hasVariable(java.lang.String name, Token token)
public void deleteVariable(java.lang.String name)
public void deleteVariable(java.lang.String name, Token token)
public java.lang.Object getTransientVariable(java.lang.String name)
public void setTransientVariable(java.lang.String name, java.lang.Object value)
public boolean hasTransientVariable(java.lang.String name)
public java.util.Map getTransientVariables()
public void setTransientVariables(java.util.Map transientVariables)
public void deleteTransientVariable(java.lang.String name)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |