|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.ode.test.MockExtensionContext
public class MockExtensionContext
Very simple mock implementation of the ExtensionContext interface.
Field Summary | |
---|---|
boolean |
completed
|
java.net.URI |
duDir
|
FaultException |
fault
|
boolean |
faulted
|
java.util.List<java.lang.String> |
msgs
|
Constructor Summary | |
---|---|
MockExtensionContext()
|
Method Summary | |
---|---|
void |
complete()
Marks the currently executed activity as successfully completed. |
void |
completeWithFault(FaultException fault)
Marks the currently executed activity as faulted. |
void |
completeWithFault(java.lang.Throwable t)
Marks the currently executed activity as faulted. |
java.lang.String |
getActivityName()
Returns the name of the invoking activity. |
java.net.URI |
getDUDir()
Returns the location of the deployment bundle of the executed process. |
OdeInternalInstance |
getInternalInstance()
Returns ODE's internal runtime instance. |
OActivity |
getOActivity()
Returns the OActivity object. |
java.lang.Long |
getProcessId()
Reads the current process instance id. |
java.util.Map<java.lang.String,org.w3c.dom.Node> |
getVariables()
|
java.util.Map<java.lang.String,OScope.Variable> |
getVisibleVariables()
Returns a list of variables visible in the current scope. |
boolean |
isLinkActive(OLink olink)
|
boolean |
isVariableVisible(java.lang.String varName)
Returns whether a variable is visible in the current scope or not. |
void |
printToConsole(java.lang.String msg)
Allows printing debug output to the console. |
java.lang.String |
readMessageProperty(OScope.Variable variable,
OProcess.OProperty property)
Read the value of a BPEL property. |
org.w3c.dom.Node |
readVariable(OScope.Variable variable)
Read the value of a BPEL variable. |
org.w3c.dom.Node |
readVariable(java.lang.String variableName)
Read the value of a BPEL variable. |
void |
writeVariable(OScope.Variable variable,
org.w3c.dom.Node value)
Write the value into a BPEL variable. |
void |
writeVariable(java.lang.String variableName,
org.w3c.dom.Node value)
Write the value into a BPEL variable. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public boolean completed
public boolean faulted
public FaultException fault
public java.net.URI duDir
public java.util.List<java.lang.String> msgs
Constructor Detail |
---|
public MockExtensionContext()
Method Detail |
---|
public java.util.Map<java.lang.String,org.w3c.dom.Node> getVariables()
public java.lang.Long getProcessId()
ExtensionContext
getProcessId
in interface ExtensionContext
public org.w3c.dom.Node readVariable(java.lang.String variableName) throws FaultException
ExtensionContext
readVariable
in interface ExtensionContext
variableName
- variable to read
Node
FaultException
public void writeVariable(java.lang.String variableName, org.w3c.dom.Node value) throws FaultException
ExtensionContext
writeVariable
in interface ExtensionContext
variableName
- variable to writevalue
- the value to be stored into the variable
FaultException
public boolean isVariableVisible(java.lang.String varName)
ExtensionContext
isVariableVisible
in interface ExtensionContext
varName
- name of the variable.
public java.lang.String getActivityName()
ExtensionContext
getActivityName
in interface ExtensionContext
public OActivity getOActivity()
ExtensionContext
getOActivity
in interface ExtensionContext
public java.util.Map<java.lang.String,OScope.Variable> getVisibleVariables() throws FaultException
ExtensionContext
getVisibleVariables
in interface ExtensionContext
FaultException
public boolean isLinkActive(OLink olink) throws FaultException
FaultException
public java.lang.String readMessageProperty(OScope.Variable variable, OProcess.OProperty property) throws FaultException
ExtensionContext
readMessageProperty
in interface ExtensionContext
variable
- variable containing propertyproperty
- property to read
FaultException
public org.w3c.dom.Node readVariable(OScope.Variable variable) throws FaultException
ExtensionContext
readVariable
in interface ExtensionContext
variable
- variable to read
Node
FaultException
public void writeVariable(OScope.Variable variable, org.w3c.dom.Node value) throws FaultException
ExtensionContext
writeVariable
in interface ExtensionContext
variable
- variable to writevalue
- the value to be stored into the variable
FaultException
public void complete()
ExtensionContext
complete
in interface ExtensionContext
public void completeWithFault(java.lang.Throwable t)
ExtensionContext
completeWithFault
in interface ExtensionContext
t
- an exception to be reported as the fault cause.public void completeWithFault(FaultException fault)
ExtensionContext
completeWithFault
in interface ExtensionContext
fault
- a fault.public OdeInternalInstance getInternalInstance()
ExtensionContext
getInternalInstance
in interface ExtensionContext
public java.net.URI getDUDir()
ExtensionContext
getDUDir
in interface ExtensionContext
public void printToConsole(java.lang.String msg)
ExtensionContext
org.apache.ode.extension.Console
.
The target log level is INFO.
printToConsole
in interface ExtensionContext
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |