Package org.activemq.message

Examples of org.activemq.message.ActiveMQTopic


    /**
     * Factory method to create new Topic instances
     */
    protected Topic createTopic(String name) {
        return new ActiveMQTopic(name);
    }
View Full Code Here


    // Implementation methods
    //-------------------------------------------------------------------------
    protected MessageContainer createContainer(String destinationName) throws JMSException {
        TopicMessageContainer topicMessageContainer =
           new DurableTopicMessageContainer(persistenceAdapter.createTopicMessageStore(destinationName), destinationName);
        destinationMap.put(new ActiveMQTopic(destinationName), topicMessageContainer);
        return topicMessageContainer;
    }
View Full Code Here

        destinationMap.put(new ActiveMQTopic(destinationName), topicMessageContainer);
        return topicMessageContainer;
    }

    protected Destination createDestination(String destinationName) {
        return new ActiveMQTopic(destinationName);
    }
View Full Code Here

    /**
     * Returns the destinations on which we publish
     */
    protected Destination[] getDestinations() {
        return new Destination[]{new ActiveMQTopic(getPrefix() + "FOO.BAR"), new ActiveMQTopic(getPrefix() + "BAR.WHATNOT.XYZ"), new ActiveMQTopic(getPrefix() + "FOO.X.Y")};
    }
View Full Code Here

    /**
     * Returns the destinations to which we consume
     */
    protected Destination[] getDestinations() {
        return new Destination[]{new ActiveMQTopic(getPrefix() + "FOO.BAR"), new ActiveMQTopic(getPrefix() + "FOO.*"), new ActiveMQTopic(getPrefix() + "FOO.X.Y")};
    }
View Full Code Here

    protected WireFormat format = new JabberWireFormat();

    public void testWrite() throws Exception {
        ActiveMQTextMessage message = new ActiveMQTextMessage();
        message.setJMSType("id");
        message.setJMSReplyTo(new ActiveMQTopic("my.source"));
        message.setJMSDestination(new ActiveMQTopic("my.target"));
        message.setJMSCorrelationID("abc123");
        message.setText("<body>hello there </body>");

        ByteArrayOutputStream buffer = new ByteArrayOutputStream();
        DataOutputStream out = new DataOutputStream(buffer);
View Full Code Here

        return createDestination(getClass().getName());
    }

    protected Destination createDestination(String name) {
        if (topic) {
            return new ActiveMQTopic(name);
        }
        else {
            return new ActiveMQQueue(name);
        }
    }
View Full Code Here

        log("Defaulting to use topics: " + defaultTopicFlag);

        name = servletConfig.getInitParameter("destination");
        if (name != null) {
            if (defaultTopicFlag) {
                defaultDestination = new ActiveMQTopic(name);
            }
            else {
                defaultDestination = new ActiveMQQueue(name);
            }
        }
View Full Code Here

            throws JMSException {
        if (queue) {
          directory.put(name, new ActiveMQQueue(name));
        }
        else {
          directory.put(name, new ActiveMQTopic(name));
        }
    }
View Full Code Here

        ActiveMQDestination dest = null;
        if (isValidDestinationType() && isValidDestination()) {
            if (Queue.class.getName().equals(destinationType)) {
                dest = new ActiveMQQueue(destination);
            } else if (Topic.class.getName().equals(destinationType)) {
                dest = new ActiveMQTopic(destination);
            } else {
                assert false : "Execution should never reach here";
            }
        }
        return dest;
View Full Code Here

TOP

Related Classes of org.activemq.message.ActiveMQTopic

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.