Class WmTopicPublisherImpl
- java.lang.Object
-
- com.webmethods.locks.Node
-
- com.webmethods.jms.impl.WmMessageProducerImpl
-
- com.webmethods.jms.impl.WmTopicPublisherImpl
-
- All Implemented Interfaces:
WmMessageProducer
,WmTopicPublisher
,javax.jms.MessageProducer
,javax.jms.TopicPublisher
- Direct Known Subclasses:
WmClusterMultiSendTopicPublisherImpl
,WmClusterTopicPublisherImpl
public class WmTopicPublisherImpl extends WmMessageProducerImpl implements WmTopicPublisher
-
-
Field Summary
-
Fields inherited from class com.webmethods.jms.impl.WmMessageProducerImpl
_destination, _logApi, _session
-
Fields inherited from class com.webmethods.locks.Node
_lockManager
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
WmTopicPublisherImpl(WmSessionImpl session, WmTopicImpl topic)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.jms.Topic
getTopic()
Gets the topic associated with thisTopicPublisher
.void
publish(javax.jms.Message message)
Publishes a message to the topic.void
publish(javax.jms.Message[] messages)
Publishes multiple messages to the topic.void
publish(javax.jms.Message[] messages, int deliveryMode, int priority, long timeToLive)
Publishes multiple messages to the topic, specifying delivery mode, priority, and time to live.void
publish(javax.jms.Message message, int deliveryMode, int priority, long timeToLive)
Publishes a message to the topic, specifying delivery mode, priority, and time to live.void
publish(javax.jms.Topic topic, javax.jms.Message message)
Publishes a message to a topic for an unidentified message producer.void
publish(javax.jms.Topic topic, javax.jms.Message[] messages)
Publishes multiple messages to a topic for an unidentified message producer.void
publish(javax.jms.Topic topic, javax.jms.Message[] messages, int deliveryMode, int priority, long timeToLive)
Publishes multiple messages to a topic for an unidentified message producer, specifying delivery mode, priority and time to live.void
publish(javax.jms.Topic topic, javax.jms.Message message, int deliveryMode, int priority, long timeToLive)
Publishes a message to a topic for an unidentified message producer, specifying delivery mode, priority and time to live.-
Methods inherited from class com.webmethods.jms.impl.WmMessageProducerImpl
checkState, close, deliveryModeToString, getCompressionLevel, getCompressionThreshold, getDeliveryMode, getDestination, getDisableMessageID, getDisableMessageTimestamp, getOutputStream, getOutputStream, getPriority, getTimeToLive, nextMessageIdentifier, reconnect, send, send, send, send, send, send, send, send, setCompressionLevel, setCompressionThreshold, setDeliveryMode, setDisableMessageID, setDisableMessageTimestamp, setPriority, setTimeToLive, toString
-
Methods inherited from class com.webmethods.locks.Node
getLockManager, getParent
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface javax.jms.MessageProducer
close, getDeliveryMode, getDestination, getDisableMessageID, getDisableMessageTimestamp, getPriority, getTimeToLive, send, send, send, send, setDeliveryMode, setDisableMessageID, setDisableMessageTimestamp, setPriority, setTimeToLive
-
Methods inherited from interface com.webmethods.jms.WmMessageProducer
getCompressionLevel, getCompressionThreshold, getOutputStream, getOutputStream, send, send, send, send, setCompressionLevel, setCompressionThreshold
-
-
-
-
Constructor Detail
-
WmTopicPublisherImpl
protected WmTopicPublisherImpl(WmSessionImpl session, WmTopicImpl topic)
-
-
Method Detail
-
getTopic
public javax.jms.Topic getTopic() throws javax.jms.JMSException
Gets the topic associated with thisTopicPublisher
.- Specified by:
getTopic
in interfacejavax.jms.TopicPublisher
- Returns:
- this publisher's topic
- Throws:
javax.jms.JMSException
- if the JMS provider fails to get the topic for thisTopicPublisher
due to some internal error.
-
publish
public void publish(javax.jms.Message message) throws javax.jms.JMSException
Publishes a message to the topic. Uses theTopicPublisher
's default delivery mode, priority, and time to live.- Specified by:
publish
in interfacejavax.jms.TopicPublisher
- Parameters:
message
- the message to publish- Throws:
javax.jms.JMSException
- if the JMS provider fails to publish the message due to some internal error.javax.jms.MessageFormatException
- if an invalid message is specified.javax.jms.InvalidDestinationException
- if a client uses this method with aTopicPublisher
with an invalid topic.java.lang.UnsupportedOperationException
- if a client uses this method with aTopicPublisher
that did not specify a topic at creation time.- See Also:
MessageProducer.getDeliveryMode()
,MessageProducer.getTimeToLive()
,MessageProducer.getPriority()
-
publish
public void publish(javax.jms.Message message, int deliveryMode, int priority, long timeToLive) throws javax.jms.JMSException
Publishes a message to the topic, specifying delivery mode, priority, and time to live.- Specified by:
publish
in interfacejavax.jms.TopicPublisher
- Parameters:
message
- the message to publishdeliveryMode
- the delivery mode to usepriority
- the priority for this messagetimeToLive
- the message's lifetime (in milliseconds)- Throws:
javax.jms.JMSException
- if the JMS provider fails to publish the message due to some internal error.javax.jms.MessageFormatException
- if an invalid message is specified.javax.jms.InvalidDestinationException
- if a client uses this method with aTopicPublisher
with an invalid topic.java.lang.UnsupportedOperationException
- if a client uses this method with aTopicPublisher
that did not specify a topic at creation time.
-
publish
public void publish(javax.jms.Topic topic, javax.jms.Message message) throws javax.jms.JMSException
Publishes a message to a topic for an unidentified message producer. Uses theTopicPublisher
's default delivery mode, priority, and time to live.Typically, a message producer is assigned a topic at creation time; however, the JMS API also supports unidentified message producers, which require that the topic be supplied every time a message is published.
- Specified by:
publish
in interfacejavax.jms.TopicPublisher
- Parameters:
topic
- the topic to publish this message tomessage
- the message to publish- Throws:
javax.jms.JMSException
- if the JMS provider fails to publish the message due to some internal error.javax.jms.MessageFormatException
- if an invalid message is specified.javax.jms.InvalidDestinationException
- if a client uses this method with an invalid topic.- See Also:
MessageProducer.getDeliveryMode()
,MessageProducer.getTimeToLive()
,MessageProducer.getPriority()
-
publish
public void publish(javax.jms.Topic topic, javax.jms.Message message, int deliveryMode, int priority, long timeToLive) throws javax.jms.JMSException
Publishes a message to a topic for an unidentified message producer, specifying delivery mode, priority and time to live.Typically, a message producer is assigned a topic at creation time; however, the JMS API also supports unidentified message producers, which require that the topic be supplied every time a message is published.
- Specified by:
publish
in interfacejavax.jms.TopicPublisher
- Parameters:
topic
- the topic to publish this message tomessage
- the message to publishdeliveryMode
- the delivery mode to usepriority
- the priority for this messagetimeToLive
- the message's lifetime (in milliseconds)- Throws:
javax.jms.JMSException
- if the JMS provider fails to publish the message due to some internal error.javax.jms.MessageFormatException
- if an invalid message is specified.javax.jms.InvalidDestinationException
- if a client uses this method with an invalid topic.
-
publish
public void publish(javax.jms.Message[] messages) throws javax.jms.JMSException
Publishes multiple messages to the topic. Uses theTopicPublisher
's default delivery mode, priority, and time to live.- Specified by:
publish
in interfaceWmTopicPublisher
- Parameters:
messages
- the messages to publish- Throws:
javax.jms.JMSException
- if the JMS provider fails to publish the message due to some internal error.javax.jms.MessageFormatException
- if an invalid message is specified.javax.jms.InvalidDestinationException
- if a client uses this method with aTopicPublisher
with an invalid topic.java.lang.UnsupportedOperationException
- if a client uses this method with aTopicPublisher
that did not specify a topic at creation time.- See Also:
MessageProducer.getDeliveryMode()
,MessageProducer.getTimeToLive()
,MessageProducer.getPriority()
-
publish
public void publish(javax.jms.Message[] messages, int deliveryMode, int priority, long timeToLive) throws javax.jms.JMSException
Publishes multiple messages to the topic, specifying delivery mode, priority, and time to live.- Specified by:
publish
in interfaceWmTopicPublisher
- Parameters:
messages
- the messages to publishdeliveryMode
- the delivery mode to usepriority
- the priority for this messagetimeToLive
- the message's lifetime (in milliseconds)- Throws:
javax.jms.JMSException
- if the JMS provider fails to publish the message due to some internal error.javax.jms.MessageFormatException
- if an invalid message is specified.javax.jms.InvalidDestinationException
- if a client uses this method with aTopicPublisher
with an invalid topic.java.lang.UnsupportedOperationException
- if a client uses this method with aTopicPublisher
that did not specify a topic at creation time.
-
publish
public void publish(javax.jms.Topic topic, javax.jms.Message[] messages) throws javax.jms.JMSException
Publishes multiple messages to a topic for an unidentified message producer. Uses theTopicPublisher
's default delivery mode, priority, and time to live.Typically, a message producer is assigned a topic at creation time; however, the JMS API also supports unidentified message producers, which require that the topic be supplied every time a message is published.
- Specified by:
publish
in interfaceWmTopicPublisher
- Parameters:
topic
- the topic to publish the messages tomessages
- the messages to publish- Throws:
javax.jms.JMSException
- if the JMS provider fails to publish the message due to some internal error.javax.jms.MessageFormatException
- if an invalid message is specified.javax.jms.InvalidDestinationException
- if a client uses this method with an invalid topic.- See Also:
MessageProducer.getDeliveryMode()
,MessageProducer.getTimeToLive()
,MessageProducer.getPriority()
-
publish
public void publish(javax.jms.Topic topic, javax.jms.Message[] messages, int deliveryMode, int priority, long timeToLive) throws javax.jms.JMSException
Publishes multiple messages to a topic for an unidentified message producer, specifying delivery mode, priority and time to live.Typically, a message producer is assigned a topic at creation time; however, the JMS API also supports unidentified message producers, which require that the topic be supplied every time a message is published.
- Specified by:
publish
in interfaceWmTopicPublisher
- Parameters:
topic
- the topic to publish the messages tomessages
- the messages to publishdeliveryMode
- the delivery mode to usepriority
- the priority for this messagetimeToLive
- the message's lifetime (in milliseconds)- Throws:
javax.jms.JMSException
- if the JMS provider fails to publish the message due to some internal error.javax.jms.MessageFormatException
- if an invalid message is specified.javax.jms.InvalidDestinationException
- if a client uses this method with an invalid topic.
-
-