Package javax.jbi.messaging

Examples of javax.jbi.messaging.DeliveryChannel.send()


        MessageExchangeFactory outputFactory = deliveryChannel.createExchangeFactory(outputEndpoint);
        InOnly inOnly = outputFactory.createInOnlyExchange();

        if (answer) {
            inOnly.setInMessage(rpc.getOutMessage());
            deliveryChannel.send(inOnly);
            done(exchange);
        }
        else if (exchange instanceof InOnly == false) {
            inOnly.setError(rpc.getError());
            Fault fault = rpc.getFault();
View Full Code Here


                DeliveryChannel deliveryChannel = context.getDeliveryChannel();
                System.out.println("sync send on deliverychannel: " + deliveryChannel);
                if (sync) {
                  deliveryChannel.sendSync(exchange);
                } else {
                  deliveryChannel.send(exchange);
                }
            }
        }
        else {
            log.warn("No endpoints available for interface: " + interfaceName);
View Full Code Here

            InOnly inonly = factory.createInOnlyExchange();
            inonly.setService(ReceiverComponent.SERVICE);
            NormalizedMessage msg = inonly.createMessage();
            msg.setContent(src);
            inonly.setInMessage(msg);
            channel.send(inonly);
        }
       
        public Source twoWay(Source src) throws Exception {
            DeliveryChannel channel = context.getDeliveryChannel();
            MessageExchangeFactory factory = channel.createExchangeFactory();
View Full Code Here

            msg.setContent(src);
            inout.setInMessage(msg);
            channel.sendSync(inout);
            Source outSrc = inout.getOutMessage().getContent();
            inout.setStatus(ExchangeStatus.DONE);
            channel.send(inout);
            return outSrc;
        }
    }
   
}
View Full Code Here

        nm.setContent(new StringSource("<request/>"));
        me.setInMessage(nm);
        channel.sendSync(me);
        assertEquals(ExchangeStatus.ACTIVE, me.getStatus());
        me.setStatus(ExchangeStatus.DONE);
        channel.send(me);
    }
   
    public static class TestComponent extends ComponentSupport {
        public TestComponent(QName service, String endpoint) {
            super(service, endpoint);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.