com.espertech.esperio.jms
Class JMSOutputAdapter

java.lang.Object
  extended by com.espertech.esperio.jms.JMSOutputAdapter
All Implemented Interfaces:
Adapter, AdapterSPI, OutputAdapter
Direct Known Subclasses:
SpringJMSTemplateOutputAdapter

public abstract class JMSOutputAdapter
extends java.lang.Object
implements OutputAdapter, AdapterSPI

Implements a JMS output adapter.


Field Summary
protected  javax.jms.Destination destination
          JMS Destination.
protected  JMSMessageMarshaller jmsMessageMarshaller
          Marshaller to use.
 
Constructor Summary
JMSOutputAdapter()
           
 
Method Summary
 void destroy()
           
 EPServiceProvider getEPServiceProvider()
           
 JMSMessageMarshaller getJmsMessageMarshaller()
          Returns the JMS message marshaller.
 AdapterState getState()
           
 Subscription getSubscription(java.lang.String subscriptionName)
           
 java.util.Map<java.lang.String,Subscription> getSubscriptionMap()
           
 void pause()
           
 void resume()
           
abstract  void send(EventBean eventBean, JMSMessageMarshaller jmsAdapterMarshaller)
          Abstract send methods for marshalling and sending an event of to JMS care.
 void setDestination(javax.jms.Destination destination)
          Sets the JMS destination.
 void setEPServiceProvider(EPServiceProvider epService)
           
 void setJmsMessageMarshaller(JMSMessageMarshaller jmsMessageMarshaller)
          Sets the JMS message marshaller.
 void setSubscriptionMap(java.util.Map<java.lang.String,Subscription> subscriptionMap)
           
 void start()
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

jmsMessageMarshaller

protected JMSMessageMarshaller jmsMessageMarshaller
Marshaller to use.


destination

protected javax.jms.Destination destination
JMS Destination.

Constructor Detail

JMSOutputAdapter

public JMSOutputAdapter()
Method Detail

send

public abstract void send(EventBean eventBean,
                          JMSMessageMarshaller jmsAdapterMarshaller)
                   throws EPException
Abstract send methods for marshalling and sending an event of to JMS care.

Parameters:
eventBean - is the event
jmsAdapterMarshaller - is the marshaller
Throws:
EPException - when the send failed

getJmsMessageMarshaller

public JMSMessageMarshaller getJmsMessageMarshaller()
Returns the JMS message marshaller.

Returns:
marshaller

setJmsMessageMarshaller

public void setJmsMessageMarshaller(JMSMessageMarshaller jmsMessageMarshaller)
Sets the JMS message marshaller.

Parameters:
jmsMessageMarshaller - is the marshaller

setDestination

public void setDestination(javax.jms.Destination destination)
Sets the JMS destination.

Parameters:
destination - is the queue or topic

getSubscriptionMap

public java.util.Map<java.lang.String,Subscription> getSubscriptionMap()
Specified by:
getSubscriptionMap in interface OutputAdapter

setSubscriptionMap

public void setSubscriptionMap(java.util.Map<java.lang.String,Subscription> subscriptionMap)
Specified by:
setSubscriptionMap in interface OutputAdapter

getSubscription

public Subscription getSubscription(java.lang.String subscriptionName)
Specified by:
getSubscription in interface OutputAdapter

getEPServiceProvider

public EPServiceProvider getEPServiceProvider()
Specified by:
getEPServiceProvider in interface AdapterSPI

setEPServiceProvider

public void setEPServiceProvider(EPServiceProvider epService)
Specified by:
setEPServiceProvider in interface AdapterSPI

start

public void start()
           throws EPException
Specified by:
start in interface Adapter
Throws:
EPException

pause

public void pause()
           throws EPException
Specified by:
pause in interface Adapter
Throws:
EPException

resume

public void resume()
            throws EPException
Specified by:
resume in interface Adapter
Throws:
EPException

stop

public void stop()
          throws EPException
Specified by:
stop in interface Adapter
Throws:
EPException

destroy

public void destroy()
             throws EPException
Specified by:
destroy in interface Adapter
Throws:
EPException

getState

public AdapterState getState()
Specified by:
getState in interface Adapter

© 2006-2011 EsperTech Inc.
All rights reserved.
Visit us at espertech.com