com.mockrunner.mock.jms.MockTopicPublisher Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of mockrunner-jdk1.3-j2ee1.3 Show documentation
Show all versions of mockrunner-jdk1.3-j2ee1.3 Show documentation
Mockrunner is a lightweight framework for unit testing applications
in the J2EE environment. It supports servlets, filters, tag classes
and Struts actions. It includes a JDBC a JMS and a JCA test
framework and can be used to test EJB based applications.
The newest version!
package com.mockrunner.mock.jms;
import javax.jms.JMSException;
import javax.jms.Message;
import javax.jms.Topic;
import javax.jms.TopicPublisher;
/**
* Mock implementation of JMS TopicPublisher
.
*/
public class MockTopicPublisher extends MockMessageProducer implements TopicPublisher
{
public MockTopicPublisher(MockConnection connection, MockSession session, MockTopic topic)
{
super(connection, session, topic);
}
public Topic getTopic() throws JMSException
{
return (Topic)getDestination();
}
public void publish(Message message) throws JMSException
{
super.send(message);
}
public void publish(Message message, int deliveryMode, int priority, long timeToLive) throws JMSException
{
super.send(message, deliveryMode, priority, timeToLive);
}
public void publish(Topic topic, Message message) throws JMSException
{
super.send(topic, message);
}
public void publish(Topic topic, Message message, int deliveryMode, int priority, long timeToLive) throws JMSException
{
super.send(topic, message, deliveryMode, priority, timeToLive);
}
}