public class TopicConnection extends Connection implements javax.jms.TopicConnection
javax.jms.TopicConnection
interface.Connection.AtomicCounter, Connection.Closer
JMXBeanBaseName, logger, messageConsumers
Constructor and Description |
---|
TopicConnection()
Creates a
TopicConnection instance. |
Modifier and Type | Method and Description |
---|---|
javax.jms.ConnectionConsumer |
createConnectionConsumer(javax.jms.Topic topic,
String selector,
javax.jms.ServerSessionPool sessionPool,
int maxMessages)
API method.
|
javax.jms.ConnectionConsumer |
createDurableConnectionConsumer(javax.jms.Topic topic,
String subName,
String selector,
javax.jms.ServerSessionPool sessPool,
int maxMessages)
API method.
|
javax.jms.TopicSession |
createTopicSession(boolean transacted,
int acknowledgeMode)
API method.
|
addSession, checkCLMessageProducer, checkClosed, checkCLSession, checkConsumers, checkThread, cleanup, close, closeConnectionConsumer, closeMessageConsumer, closeSession, createConnectionConsumer, createSession, createSession, createSession, createSharedConnectionConsumer, createSharedDurableConnectionConsumer, doClose, equals, getAsyncSend, getClientID, getCompressedMinSize, getCompressionLevel, getExceptionListener, getImplicitAck, getInInterceptors, getJMXBeanName, getMetaData, getOutInterceptors, getOutLocalAddress, getOutLocalPort, getQueueMessageReadMax, getRequestMultiplexer, getTopicAckBufferMax, getTopicActivationThreshold, getTopicPassivationThreshold, getTxPendingTimer, hashCode, isOpenMessageConsumer, isStopped, lockClientId, nextMessageId, nextSessionId, nextSubName, open, openMessageConsumer, registerMBean, setClientID, setExceptionListener, setJMXBeanBaseName, setProviderClientID, start, stop, syncRequest, toString, unregisterMBean
public javax.jms.ConnectionConsumer createConnectionConsumer(javax.jms.Topic topic, String selector, javax.jms.ServerSessionPool sessionPool, int maxMessages) throws javax.jms.JMSException
createConnectionConsumer
in interface javax.jms.TopicConnection
topic
- the topic to access.selector
- only messages with properties matching the message selector expression
are delivered. A value of null or an empty string indicates that there is
no message selector for this message consumer.sessionPool
- the server session pool to associate with this connection consumer.maxMessages
- the maximum number of messages that can be assigned to a server session
at one time.javax.jms.IllegalStateException
- If the connection is closed.javax.jms.InvalidSelectorException
- If the selector syntax is wrong.javax.jms.InvalidDestinationException
- If the target destination does
not exist.javax.jms.JMSException
- If the method fails for any other reason.public javax.jms.TopicSession createTopicSession(boolean transacted, int acknowledgeMode) throws javax.jms.JMSException
createTopicSession
in interface javax.jms.TopicConnection
transacted
- indicates whether the session is transacted.acknowledgeMode
- indicates whether the consumer or the client will acknowledge any
messages it receives; ignored if the session is transacted. Legal
values are Session.AUTO_ACKNOWLEDGE, Session.CLIENT_ACKNOWLEDGE, and
Session.DUPS_OK_ACKNOWLEDGE.javax.jms.IllegalStateException
- If the connection is closed.javax.jms.JMSException
- In case of an invalid acknowledge mode.public javax.jms.ConnectionConsumer createDurableConnectionConsumer(javax.jms.Topic topic, String subName, String selector, javax.jms.ServerSessionPool sessPool, int maxMessages) throws javax.jms.JMSException
createDurableConnectionConsumer
in interface javax.jms.Connection
createDurableConnectionConsumer
in interface javax.jms.TopicConnection
createDurableConnectionConsumer
in class Connection
topic
- the topic to access.subName
- durable subscription name.selector
- only messages with properties matching the message selector expression
are delivered. A value of null or an empty string indicates that there
is no message selector for this message consumer.sessPool
- the server session pool to associate with this connection consumer.maxMessages
- the maximum number of messages that can be assigned to a server session
at one time.javax.jms.IllegalStateException
- If the connection is closed.javax.jms.InvalidSelectorException
- If the selector syntax is wrong.javax.jms.InvalidDestinationException
- If the target topic does
not exist.javax.jms.JMSException
- If the method fails for any other reason.Copyright © 2018 ScalAgent D.T.. All Rights Reserved.