net.sf.xbus.technical.mq
Class MQReceiverThread

java.lang.Object
  extended by net.sf.xbus.technical.ReceiverThreadBase
      extended by net.sf.xbus.technical.mq.MQReceiverThread
All Implemented Interfaces:
java.lang.Runnable, Receiver

public class MQReceiverThread
extends ReceiverThreadBase

TODO Kommentierung


Field Summary
 
Fields inherited from class net.sf.xbus.technical.ReceiverThreadBase
DEFAULT_ERROR_TIMEOUT, DEFAULT_TIMEOUT
 
Constructor Summary
MQReceiverThread(XBUSSystem source)
          Stores the interface name
 
Method Summary
protected  java.lang.String getAddress()
          Returns the name of the message queue.
protected  java.lang.String getReceiverClassName()
          Returns the name of the receiver class, used for example to determine values in the configuration.
 java.lang.String getType()
          Returns Constants.TYPE_TEXT
protected  void initializeThread()
          Opens a MQConnection.
protected  java.lang.Object receive()
          Receives one message.
protected  void registerResources(TAManager taManager)
          Registers the MQConnectionin the TAManager.
 
Methods inherited from class net.sf.xbus.technical.ReceiverThreadBase
checkProceed, getErrorTimeout, getSource, getTimeout, incrementErrorCounter, initializeErrorCounter, interruptThread, run
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MQReceiverThread

public MQReceiverThread(XBUSSystem source)
Stores the interface name

Parameters:
source - name of the interface definition
Method Detail

initializeThread

protected void initializeThread()
                         throws XException
Opens a MQConnection.

Specified by:
initializeThread in class ReceiverThreadBase
Throws:
XException - if something goes wrong

registerResources

protected void registerResources(TAManager taManager)
                          throws XException
Registers the MQConnectionin the TAManager.

Specified by:
registerResources in class ReceiverThreadBase
Parameters:
taManager - the transaction manager in which the resources shall be registered
Throws:
XException - if something goes wrong

receive

protected java.lang.Object receive()
                            throws XException
Description copied from class: ReceiverThreadBase
Receives one message.

Specified by:
receive in class ReceiverThreadBase
Returns:
the received message or null when no message has been available
Throws:
XException - if something goes wrong
See Also:
ReceiverThreadBase.receive()

getType

public java.lang.String getType()
Returns Constants.TYPE_TEXT

Returns:
Constants.TYPE_TEXT

getReceiverClassName

protected java.lang.String getReceiverClassName()
Description copied from class: ReceiverThreadBase
Returns the name of the receiver class, used for example to determine values in the configuration.

Specified by:
getReceiverClassName in class ReceiverThreadBase
Returns:
the name of the receiver class
See Also:
ReceiverThreadBase.getReceiverClassName()

getAddress

protected java.lang.String getAddress()
Returns the name of the message queue.

Specified by:
getAddress in class ReceiverThreadBase
Returns:
the name of the message queue