public class JMSMessageSender extends Object implements ProviderMessageSender
| Constructor and Description |
|---|
JMSMessageSender() |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
protected javax.jms.MessageProducer |
getProducer(javax.jms.Destination dest)
returns producer for the specified destination
|
void |
init()
initializes message sender, creating new session and connecting to the message queue.
|
void |
sendMessageInternal(TransferMessage transferMessage)
Sends a message to the message queue internally
|
void |
sendReplyMessage(TransferMessage transferMessage)
sends received message to the MQ
|
void |
setSession(javax.jms.Session session)
Method to set the session.
|
public void close()
protected javax.jms.MessageProducer getProducer(javax.jms.Destination dest)
throws javax.jms.JMSException
dest - destinationjavax.jms.JMSException - exceptionpublic void init()
throws javax.jms.JMSException
javax.jms.JMSException - exceptionpublic void sendMessageInternal(TransferMessage transferMessage) throws MessageQueueCommunicationException
sendMessageInternal in interface ProviderMessageSendertransferMessage - the transfer message to sendMessageQueueCommunicationExceptionpublic void sendReplyMessage(TransferMessage transferMessage) throws MessageQueueCommunicationException
sendReplyMessage in interface ProviderMessageSendertransferMessage - message to be sentMessageQueueCommunicationExceptionpublic void setSession(javax.jms.Session session)
session - JMS session to be setCopyright © 2019 Communote team. All rights reserved.