com.createtank.elemenope
Interface Dispatcher

All Superinterfaces:
ElemenopeComponent, ElemenopeConnectionEntity
All Known Subinterfaces:
FailoverDispatcher
All Known Implementing Classes:
DirectCallDispatcher, DispatcherFailoverImpl, DistributionListDispatcher, JmsQueueDispatcher, SoapDispatcher, SoapMethodDispatcher, SynchronousJmsQueueDispatcher, XmlRpcDispatcher, XmlRpcElemenopeDispatcher

public interface Dispatcher
extends ElemenopeComponent, ElemenopeConnectionEntity

interface for all Dispatcher classes.

To use a Dispatcher, one need know nothing of the implementation or transport configured...

 // create an object of the known response type (the Object type which is returned by your Operation class).
 ResponseType = null;

 // create an object of the known parameter type (the Object type which is accepted by your Operation class).
 // this may be any Object type, as defined within your application.
 DispatchType bean = new DispatchType();
 // populate bean...

 // declare an ElemenopeDispatchResponse object (the object will be returned by the Dispatcher.send() method).
 ElemenopeDispatchResponse edr=null;

 // call the send() method, passing the name of the Operation as configured...
 edr=dispatcher.send("OPERATIONNAME", bean);

 // extract the response...
 response = (ResponseType)edr.getDispatchResponse();

 // do something with the response object...
 

Author:
John Joseph Roets [joe@createtank.com]

Method Summary
 ElemenopeDispatchResponse send(OperationType object)
          Sends TrnasactionType Object through configured Connection entity.
 ElemenopeDispatchResponse send(java.lang.String operationType, java.lang.Object object)
          Sends generic Object through configured Connection entity.
 ElemenopeDispatchResponse send(java.lang.String operationType, java.lang.Object object, java.util.Map atts)
          Sends generic Object through configured Connection entity.
 
Methods inherited from interface com.createtank.elemenope.ElemenopeComponent
releaseComponents, setComponents, setConfigurationAttributes
 
Methods inherited from interface com.createtank.elemenope.ElemenopeConnectionEntity
getConnectionAttributes, setConnectionAttributes
 

Method Detail

send

ElemenopeDispatchResponse send(OperationType object)
                               throws ElemenopeException
Sends TrnasactionType Object through configured Connection entity.

Parameters:
object -
Returns:
Throws:
ElemenopeException

send

ElemenopeDispatchResponse send(java.lang.String operationType,
                               java.lang.Object object)
                               throws ElemenopeException
Sends generic Object through configured Connection entity.

Parameters:
operationType - configured name of operation to execute.
object - Object to send.
Returns:
ElemenopeDispatchResponse object containing data returned and further information on the dispatch path and DispatcherFailover [DFO] information.
Throws:
ElemenopeException

send

ElemenopeDispatchResponse send(java.lang.String operationType,
                               java.lang.Object object,
                               java.util.Map atts)
                               throws ElemenopeException
Sends generic Object through configured Connection entity.

Parameters:
operationType - configured name of operation to execute.
object - Object to send.
atts - attributes to send along with message if applicable.
Returns:
ElemenopeDispatchResponse object containing data returned and further information on the dispatch path and DispatcherFailover [DFO] information.
Throws:
ElemenopeException