com.opensymphony.workflow.util
Class EJBInvoker
java.lang.Object
com.opensymphony.workflow.util.EJBInvoker
- All Implemented Interfaces:
- FunctionProvider
public class EJBInvoker
- extends Object
- implements FunctionProvider
Generic EJB Invoker function.
This function is used to invoke an EJB listener in a step. The EJB
must implement WorkflowListener if it's a remote session bean, or
WorkflowLocalListener if it's a local session bean.
It accepts a number of arguments, these are:
- ejb-home - The fully qualified class name of the EJB remote home interface
- ejb-local-home - The fully qualified class name of the local home interface
- ejb-jndi-location - The JNDI location of the ejb to invoke
Note that only one of ejb-home or ejb-local-home can be specified.
Also, please note that the entire set of properties will be passed through to the
constructor for InitialContext, meaning that if you need to use an
InintialContextFactory other than the default one, you are free to include arguments
that will do so.
- Version:
- $Revision: 1.2 $
Date: Apr 6, 2002
Time: 11:48:14 PM
- Author:
- Hani Suleiman
|
Method Summary |
void |
execute(Map transientVars,
Map args,
com.opensymphony.module.propertyset.PropertySet ps)
Execute this function |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
EJBInvoker
public EJBInvoker()
execute
public void execute(Map transientVars,
Map args,
com.opensymphony.module.propertyset.PropertySet ps)
- Description copied from interface:
FunctionProvider
- Execute this function
- Specified by:
execute in interface FunctionProvider
- Parameters:
transientVars - Variables that will not be persisted. These include inputs
given in the Workflow.initialize(java.lang.String, int, java.util.Map) and Workflow.doAction(long, int, java.util.Map) method calls.
There are a number of special variable names:
entry: (object type: WorkflowEntry)
The workflow instance
context:
(object type: WorkflowContext). The workflow context.
actionId: The Integer ID of the current action that was take (if applicable).
currentSteps: A Collection of the current steps in the workflow instance.
store: The WorkflowStore.
descriptor: The WorkflowDescriptor.
Also, any variable set as a Register), will also be
available in the transient map, no matter what. These transient variables only last through
the method call that they were invoked in, such as Workflow.initialize(java.lang.String, int, java.util.Map)
and Workflow.doAction(long, int, java.util.Map).args - The properties for this function invocation. Properties are created
from arg nested elements within the xml, an arg element takes in a name attribute
which is the properties key, and the CDATA text contents of the element map to
the property value.ps - The persistent variables that are associated with the current
instance of the workflow. Any change made to the propertyset are persisted to
the propertyset implementation's persistent store.