it.imolinfo.jbi4corba.jbi.component.runtime
Class AbstractMessageExchangeHandler

java.lang.Object
  extended by it.imolinfo.jbi4corba.jbi.component.runtime.AbstractMessageExchangeHandler
All Implemented Interfaces:
MessageExchangeHandler, Runnable
Direct Known Subclasses:
DefaultMessageExchangeHandler, Jbi4CorbaMessageExchangeHandler

public abstract class AbstractMessageExchangeHandler
extends Object
implements MessageExchangeHandler

This class is an abstract implemenation of the MessageExchangeHandler which provides the base implemenation of the ME processing and provides hooks to extended classes to implement component specific processing.

Author:
Marco Piraccini

Field Summary
static String IN_MESSAGE
           
static String OUT_MESSAGE
           
 
Constructor Summary
protected AbstractMessageExchangeHandler()
          Creates a new instance of AbstractMessageExchangeHandler
 
Method Summary
protected  javax.jbi.messaging.DeliveryChannel getDeliveryChannel()
           
 javax.jbi.messaging.MessageExchange getMessageExchange()
           
protected abstract  void processDone()
           
protected abstract  void processError(Exception ex)
           
protected abstract  void processFault(javax.jbi.messaging.Fault fault)
           
protected abstract  void processMessage()
           
 void processMessageExchange()
          command interface method which will be invoked to process the MessageExchange object set using setMessageExchange.
 void run()
           
protected  void send()
           
protected  void sendDone()
           
protected  void sendError(Exception ex)
           
protected  void sendFault()
           
protected  void sendFault(Exception ex)
           
protected  void sendFault(javax.jbi.messaging.Fault fault)
           
 void setMessageExchange(javax.jbi.messaging.MessageExchange msgExchange)
          sets the MessageExchange object to be processed
protected abstract  void validateMessageExchange()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

IN_MESSAGE

public static String IN_MESSAGE

OUT_MESSAGE

public static String OUT_MESSAGE
Constructor Detail

AbstractMessageExchangeHandler

protected AbstractMessageExchangeHandler()
Creates a new instance of AbstractMessageExchangeHandler

Method Detail

getDeliveryChannel

protected final javax.jbi.messaging.DeliveryChannel getDeliveryChannel()

getMessageExchange

public final javax.jbi.messaging.MessageExchange getMessageExchange()

setMessageExchange

public final void setMessageExchange(javax.jbi.messaging.MessageExchange msgExchange)
Description copied from interface: MessageExchangeHandler
sets the MessageExchange object to be processed

Specified by:
setMessageExchange in interface MessageExchangeHandler
Parameters:
msgExchange - MessageExchange object.

send

protected final void send()
                   throws javax.jbi.messaging.MessagingException
Throws:
javax.jbi.messaging.MessagingException

sendDone

protected final void sendDone()
                       throws javax.jbi.messaging.MessagingException
Throws:
javax.jbi.messaging.MessagingException

sendFault

protected final void sendFault()
                        throws javax.jbi.messaging.MessagingException
Throws:
javax.jbi.messaging.MessagingException

sendFault

protected final void sendFault(Exception ex)
                        throws javax.jbi.messaging.MessagingException
Throws:
javax.jbi.messaging.MessagingException

sendFault

protected void sendFault(javax.jbi.messaging.Fault fault)
                  throws javax.jbi.messaging.MessagingException
Throws:
javax.jbi.messaging.MessagingException

sendError

protected final void sendError(Exception ex)

validateMessageExchange

protected abstract void validateMessageExchange()
                                         throws javax.jbi.messaging.MessagingException
Throws:
javax.jbi.messaging.MessagingException

processError

protected abstract void processError(Exception ex)

processDone

protected abstract void processDone()

processMessage

protected abstract void processMessage()

processFault

protected abstract void processFault(javax.jbi.messaging.Fault fault)

processMessageExchange

public final void processMessageExchange()
Description copied from interface: MessageExchangeHandler
command interface method which will be invoked to process the MessageExchange object set using setMessageExchange.

Specified by:
processMessageExchange in interface MessageExchangeHandler

run

public final void run()
Specified by:
run in interface Runnable


Copyright © 2005-2010 Imola Informatica. All Rights Reserved.