org.apache.ode.bpel.evar
Interface ExternalVariableModule

All Known Implementing Classes:
JdbcExternalVariableModule

public interface ExternalVariableModule

Representation of an external source for variable data.


Nested Class Summary
static class ExternalVariableModule.Locator
          Structure used to identify an external variable to the external variable subsystem.
static class ExternalVariableModule.Value
          Data structure used to report the value of the variable to the BPEL engine from the external sub system.
 
Method Summary
 void configure(javax.xml.namespace.QName pid, java.lang.String extVarId, org.w3c.dom.Element config)
          Configure an external variable.
 javax.xml.namespace.QName getName()
          Get the QName of this external variable engine; this method must always return a valid non-null value.
 boolean isTransactional()
          Report whether this engine is transactional, i.e.
 ExternalVariableModule.Value readValue(javax.xml.namespace.QName varType, ExternalVariableModule.Locator locator)
          The the value of an external variable.
 void shutdown()
          Shutdown the external variable subsystem.
 void start()
          Start the external variable subsystem.
 void stop()
          Stop the external variable subsystem.
 ExternalVariableModule.Value writeValue(javax.xml.namespace.QName varType, ExternalVariableModule.Value newval)
          Update the value of the external variable.
 

Method Detail

getName

javax.xml.namespace.QName getName()
Get the QName of this external variable engine; this method must always return a valid non-null value. The name of the external variable engine is used to identify it in the external variable declaration.

Returns:

start

void start()
Start the external variable subsystem. This method is called before the engine is started.


stop

void stop()
Stop the external variable subsystem. This method is called right after the engine is stopped.


shutdown

void shutdown()
Shutdown the external variable subsystem. This method is called right after the engine is shutdown.


isTransactional

boolean isTransactional()
Report whether this engine is transactional, i.e. do the update/fetch methods use the JTA TX?

Returns:
true if transactional, false otherwsie.

configure

void configure(javax.xml.namespace.QName pid,
               java.lang.String extVarId,
               org.w3c.dom.Element config)
               throws ExternalVariableModuleException
Configure an external variable.

Parameters:
pid - process
extVarId - external variable identifier
config - configuration element
Throws:
ExternalVariableModuleException

readValue

ExternalVariableModule.Value readValue(javax.xml.namespace.QName varType,
                                       ExternalVariableModule.Locator locator)
                                       throws ExternalVariableModuleException
The the value of an external variable.

Parameters:
locator - variable locator
initialize - indicates if this is the first time the value is being read
Returns:
value of the variable
Throws:
ExternalVariableModuleException

writeValue

ExternalVariableModule.Value writeValue(javax.xml.namespace.QName varType,
                                        ExternalVariableModule.Value newval)
                                        throws ExternalVariableModuleException
Update the value of the external variable.

Parameters:
newval - new variable value
initialize - indicates if this is a variable initialization
Throws:
ExternalVariableModuleException