Package org.activemq.ws.xmlbeans.notification.base.NotifyDocument

Examples of org.activemq.ws.xmlbeans.notification.base.NotifyDocument.Notify


        Session session = connection.createSession(false, 0);
        ActiveMQTopic topic = new ActiveMQTopic("Test");
        MessageConsumer consumer = session.createConsumer(topic);
       
        NotifyDocument request = NotifyDocument.Factory.newInstance();
        Notify notify = request.addNewNotify();
        NotificationMessageHolderType messageHolder = notify.addNewNotificationMessage();
        messageHolder.setTopic( TopicExpressionConverter.toTopicExpression(topic) );
        XmlObject o = createMessage();
        messageHolder.setMessage(o);
       
        System.out.println(request);
View Full Code Here


        return responseDoc;
    }

    public void notify(NotifyDocument requestDoc) {
        try {
            Notify notify = requestDoc.getNotify();
            NotificationMessageHolderType[] messageHolders = notify.getNotificationMessageArray();
            for (int i = 0; i < messageHolders.length; i++) {
                NotificationMessageHolderType messageHolder = messageHolders[i];
                Topic topic = TopicExpressionConverter.toActiveMQTopic(messageHolder.getTopic());           
                EndpointReferenceType producerReference = messageHolder.getProducerReference();
                if( producerReference != null ) {
View Full Code Here

       
    }

    private void dispatch(TopicExpressionType topic, XmlObject xml) {
        NotifyDocument request = NotifyDocument.Factory.newInstance();
        Notify notify = request.addNewNotify();
        NotificationMessageHolderType messageHolder = notify.addNewNotificationMessage();
        if( producerReference!=null )
            messageHolder.setProducerReference((EndpointReferenceType) producerReference.copy());
        messageHolder.setTopic(topic);
        messageHolder.setMessage(xml);
View Full Code Here

TOP

Related Classes of org.activemq.ws.xmlbeans.notification.base.NotifyDocument.Notify

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.