All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.mockrunner.mock.jms.MockTopicPublisher Maven / Gradle / Ivy

There is a newer version: 2.0.7
Show 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);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy