Package org.mule.processor.chain

Examples of org.mule.processor.chain.DefaultMessageProcessorChainBuilder.chain()


            }
        });

        chainBuilder.chain(createCxfOutboundMessageProcessor(config.getSecurity()));

        chainBuilder.chain(new AbstractInterceptingMessageProcessor()
        {
            @Override
            public MuleEvent process(MuleEvent event) throws MuleException
            {
                // Remove outbound properties that are mapped to SOAP headers, so that the
View Full Code Here


                return result;
            }
        });

        chainBuilder.chain(config.createOutboundMessageProcessor());

        return chainBuilder.build();
    }

    /**
 
View Full Code Here

                DefaultMessageProcessorChainBuilder chainBuilder = new DefaultMessageProcessorChainBuilder(
                    flowConstruct);
                chainBuilder.setName("Component interceptor processor chain for :" + getName());
                for (Interceptor interceptor : interceptors)
                {
                    chainBuilder.chain(interceptor);
                }
                chainBuilder.chain(new MessageProcessor()
                {
                    public MuleEvent process(MuleEvent event) throws MuleException
                    {
View Full Code Here

                chainBuilder.setName("Component interceptor processor chain for :" + getName());
                for (Interceptor interceptor : interceptors)
                {
                    chainBuilder.chain(interceptor);
                }
                chainBuilder.chain(new MessageProcessor()
                {
                    public MuleEvent process(MuleEvent event) throws MuleException
                    {
                        return invokeInternal(event);
                    }
View Full Code Here

        DefaultMessageProcessorChainBuilder builder = new DefaultMessageProcessorChainBuilder();
        for (Object messageProcessor : messageProcessors)
        {
            if (messageProcessor instanceof MessageProcessor)
            {
                builder.chain(((MessageProcessor) messageProcessor));
                continue;
            }
            if (messageProcessor instanceof MessageProcessorBuilder)
            {
                builder.chain(((MessageProcessorBuilder) messageProcessor));
View Full Code Here

                builder.chain(((MessageProcessor) messageProcessor));
                continue;
            }
            if (messageProcessor instanceof MessageProcessorBuilder)
            {
                builder.chain(((MessageProcessorBuilder) messageProcessor));
                continue;
            }
        }
        return builder.build();
    }
View Full Code Here

    @Test
    public void testResponseAdaptorSingleMP() throws MuleException, Exception
    {
        DefaultMessageProcessorChainBuilder builder = new DefaultMessageProcessorChainBuilder();
        builder.chain(new StringAppendTransformer("1"), new ResponseMessageProcessorAdapter(
            new StringAppendTransformer("3")), new StringAppendTransformer("2"));
        assertEquals("0123", builder.build().process(getTestEventUsingFlow("0")).getMessageAsString());
    }

    @Test
View Full Code Here

    @Test
    public void testResponseAdaptorSingleMPReturnsNull() throws MuleException, Exception
    {
        DefaultMessageProcessorChainBuilder builder = new DefaultMessageProcessorChainBuilder();
        builder.chain(new StringAppendTransformer("1"), new ResponseMessageProcessorAdapter(
            new ReturnNullMP()), new StringAppendTransformer("2"));
        assertEquals("012", builder.build().process(getTestEventUsingFlow("0")).getMessageAsString());
    }

    @Test
View Full Code Here

    @Test
    public void testResponseAdaptorNestedChain() throws MuleException, Exception
    {
        DefaultMessageProcessorChainBuilder builder = new DefaultMessageProcessorChainBuilder();
        builder.chain(
            new StringAppendTransformer("1"),
            new ResponseMessageProcessorAdapter(new DefaultMessageProcessorChainBuilder().chain(
                new StringAppendTransformer("a"), new StringAppendTransformer("b")).build()),
            new StringAppendTransformer("2"));
        assertEquals("012ab", builder.build().process(getTestEventUsingFlow("0")).getMessageAsString());
View Full Code Here

    @Test
    public void testResponseAdaptorNestedChainReturnsNull() throws MuleException, Exception
    {
        DefaultMessageProcessorChainBuilder builder = new DefaultMessageProcessorChainBuilder();
        builder.chain(
            new StringAppendTransformer("1"),
            new ResponseMessageProcessorAdapter(new DefaultMessageProcessorChainBuilder().chain(
                new StringAppendTransformer("a"), new StringAppendTransformer("b"), new ReturnNullMP())
                .build()), new StringAppendTransformer("2"));
        assertEquals("012", builder.build().process(getTestEventUsingFlow("0")).getMessageAsString());
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.