com.mockrunner.mock.jms
Class MockTopic

java.lang.Object
  extended by com.mockrunner.mock.jms.MockDestination
      extended by com.mockrunner.mock.jms.MockTopic
All Implemented Interfaces:
java.io.Serializable, javax.jms.Destination, javax.jms.Topic
Direct Known Subclasses:
MockTemporaryTopic

public class MockTopic
extends MockDestination
implements javax.jms.Topic

Mock implementation of JMS Topic.

See Also:
Serialized Form

Constructor Summary
MockTopic(java.lang.String name)
           
 
Method Summary
 void addMessage(javax.jms.Message message)
          Adds a message to this Topic that will be propagated to the corresponding receivers.
 java.lang.String getTopicName()
           
 
Methods inherited from class com.mockrunner.mock.jms.MockDestination
acknowledgeMessage, addCurrentMessage, addReceivedMessage, addSession, clear, getCurrentMessageList, getMatchingMessage, getMessage, getReceivedMessageList, isEmpty, loadMessage, removeSession, reset, sessionSet
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.jms.Topic
toString
 

Constructor Detail

MockTopic

public MockTopic(java.lang.String name)
Method Detail

getTopicName

public java.lang.String getTopicName()
                              throws javax.jms.JMSException
Specified by:
getTopicName in interface javax.jms.Topic
Throws:
javax.jms.JMSException

addMessage

public void addMessage(javax.jms.Message message)
                throws javax.jms.JMSException
Adds a message to this Topic that will be propagated to the corresponding receivers.

Specified by:
addMessage in class MockDestination
Parameters:
message - the message
Throws:
javax.jms.JMSException