public class TopicTransmissionManager extends Object implements Serializable
| Constructor and Description |
|---|
TopicTransmissionManager(MockConnection connection,
MockSession session) |
| Modifier and Type | Method and Description |
|---|---|
void |
closeAll()
Closes all senders, receivers, browsers, publishers and subscribers.
|
void |
closeAllTopicDurableSubscribers()
Closes all durable topic subscribers.
|
void |
closeAllTopicPublishers()
Closes all topic publishers.
|
void |
closeAllTopicSubscribers()
Closes all topic subscribers.
|
MockTopicSubscriber |
createDurableTopicSubscriber(MockTopic topic,
String name,
String messageSelector,
boolean noLocal)
Creates a new durable
TopicSubscriber for the specified
Topic. |
MockTopicPublisher |
createTopicPublisher(MockTopic topic)
Creates a new
TopicPublisher for the specified
Topic. |
MockTopicSubscriber |
createTopicSubscriber(MockTopic topic,
String messageSelector,
boolean noLocal)
Creates a new
TopicSubscriber for the specified
Topic. |
MockTopicSubscriber |
getDurableTopicSubscriber(String name)
Returns a durable
TopicSubscriber by its name or
null, if no such durable TopicSubscriber is
present. |
Map |
getDurableTopicSubscriberMap()
Returns the map of all durable
TopicSubscriber objects. |
Map |
getDurableTopicSubscriberMap(String topicName)
Returns the map of all durable
TopicSubscriber objects
for a specific Topic. |
MockTopicPublisher |
getTopicPublisher(int index)
Returns a
TopicPublisher by its index or
null, if no such TopicPublisher is
present. |
MockTopicPublisher |
getTopicPublisher(String topicName)
Returns a
TopicPublisher by the name of its
corresponding Topic. |
List |
getTopicPublisherList()
Returns the list of all
TopicPublisher objects. |
List |
getTopicPublisherList(String topicName)
Returns the list of the
TopicPublisher objects
for a specific Topic. |
MockTopicSubscriber |
getTopicSubscriber(int index)
Returns a
TopicSubscriber by its index or
null, if no such TopicSubscriber is
present. |
MockTopicSubscriber |
getTopicSubscriber(String topicName)
Returns a
TopicSubscriber by the name of its
corresponding Topic. |
List |
getTopicSubscriberList()
Returns the list of all
TopicSubscriber objects. |
List |
getTopicSubscriberList(String topicName)
Returns the list of the
TopicSubscriber objects
for a specific Topic. |
void |
removeTopicDurableSubscriber(String name)
Deletes a durable
TopicSubscriber. |
public TopicTransmissionManager(MockConnection connection, MockSession session)
public void closeAll()
public void closeAllTopicPublishers()
public void closeAllTopicSubscribers()
public void closeAllTopicDurableSubscribers()
public MockTopicPublisher createTopicPublisher(MockTopic topic)
TopicPublisher for the specified
Topic. Usually this method is called
by MockTopicSession.createPublisher(javax.jms.Topic).topic - the TopicTopicPublisherpublic MockTopicPublisher getTopicPublisher(int index)
TopicPublisher by its index or
null, if no such TopicPublisher is
present.index - the index of the TopicPublisherTopicPublisherpublic MockTopicPublisher getTopicPublisher(String topicName)
TopicPublisher by the name of its
corresponding Topic. If there's more than
one TopicPublisher object for the specified name,
the first one will be returned.topicName - the name of the TopicTopicPublisherpublic List getTopicPublisherList(String topicName)
TopicPublisher objects
for a specific Topic.topicName - the name of the TopicTopicPublisher objectspublic List getTopicPublisherList()
TopicPublisher objects.TopicPublisher objectspublic MockTopicSubscriber createTopicSubscriber(MockTopic topic, String messageSelector, boolean noLocal)
TopicSubscriber for the specified
Topic. Usually this method is called
by MockTopicSession.createSubscriber(javax.jms.Topic).topic - the TopicmessageSelector - the message selectornoLocal - the no local flagTopicSubscriberpublic MockTopicSubscriber getTopicSubscriber(int index)
TopicSubscriber by its index or
null, if no such TopicSubscriber is
present.index - the index of the TopicSubscriberTopicSubscriberpublic MockTopicSubscriber getTopicSubscriber(String topicName)
TopicSubscriber by the name of its
corresponding Topic. If there's more than
one TopicSubscriber object for the specified name,
the first one will be returned.topicName - the name of the TopicTopicSubscriberpublic List getTopicSubscriberList(String topicName)
TopicSubscriber objects
for a specific Topic.topicName - the name of the TopicTopicSubscriber objectspublic List getTopicSubscriberList()
TopicSubscriber objects.TopicSubscriber objectspublic MockTopicSubscriber createDurableTopicSubscriber(MockTopic topic, String name, String messageSelector, boolean noLocal)
TopicSubscriber for the specified
Topic. Usually this method is called
by MockSession.createDurableSubscriber(javax.jms.Topic, java.lang.String).topic - the Topicname - the name of the subscriptionmessageSelector - the message selectornoLocal - the no local flagTopicSubscriberpublic MockTopicSubscriber getDurableTopicSubscriber(String name)
TopicSubscriber by its name or
null, if no such durable TopicSubscriber is
present.name - the name of the subscriptionTopicSubscriberpublic void removeTopicDurableSubscriber(String name)
TopicSubscriber.name - the name of the subscriptionpublic Map getDurableTopicSubscriberMap(String topicName)
TopicSubscriber objects
for a specific Topic.topicName - the name of the TopicTopicSubscriber objectspublic Map getDurableTopicSubscriberMap()
TopicSubscriber objects.TopicSubscriber objectsCopyright © 2003–2020. All rights reserved.