public class TopicPublisherImpl extends MessageProducerImpl implements TopicPublisher
_queue, _session, DEFAULT_TIME_TO_LIVE
Constructor and Description |
---|
TopicPublisherImpl(JmsSession session,
AbstractTopic topic) |
Modifier and Type | Method and Description |
---|---|
Topic |
getTopic()
Returns the topic
|
void |
publish(Message message)
Publishes a message to the topic
|
void |
publish(Message message,
int deliveryMode,
int priority,
long timeToLive)
Publishes a message to the topic
|
void |
publish(Topic topic,
Message message)
Publishes a message to the topic
|
void |
publish(Topic topic,
Message message,
int deliveryMode,
int priority,
long timeToLive)
Publishes a message to the topic
|
calculateExpiration, close, getDeliveryMode, getDestination, getDisableMessageID, getDisableMessageTimestamp, getPriority, getTimeToLive, send, send, send, send, setDeliveryMode, setDisableMessageID, setDisableMessageTimestamp, setPriority, setTimeToLive, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
close, getDeliveryMode, getDestination, getDisableMessageID, getDisableMessageTimestamp, getPriority, getTimeToLive, send, send, send, send, setDeliveryMode, setDisableMessageID, setDisableMessageTimestamp, setPriority, setTimeToLive
public TopicPublisherImpl(JmsSession session, AbstractTopic topic)
public Topic getTopic() throws JMSException
getTopic
in interface TopicPublisher
JMSException
public void publish(Message message) throws JMSException
publish
in interface TopicPublisher
message
- the message to publishJMSException
public void publish(Message message, int deliveryMode, int priority, long timeToLive) throws JMSException
publish
in interface TopicPublisher
message
- the message to publishdeliveryMode
- the delivery modepriority
- the prioritytimeToLive
- how long the message should liveJMSException
public void publish(Topic topic, Message message) throws JMSException
publish
in interface TopicPublisher
topic
- the topic the message should be publish tomessage
- the message to publishJMSException
public void publish(Topic topic, Message message, int deliveryMode, int priority, long timeToLive) throws JMSException
publish
in interface TopicPublisher
topic
- the topic the message should be publish tomessage
- the message to publishdeliveryMode
- the delivery modepriority
- the prioritytimeToLive
- how long the message should liveJMSException