Package org.mule.api

Examples of org.mule.api.MuleContext


    private String wsdlPort;
    private String operation;

    protected MuleMessage doInvoke(MuleEvent event) throws Exception
    {
        MuleContext muleContext = event.getMuleContext();

        String tempUrl;
        if (addressFromMessage)
        {
            tempUrl = event.getMessage().getInboundProperty(WS_SERVICE_URL);
View Full Code Here


        return null;
    }

    public void testCreateMuleContext() throws Exception
    {
        MuleContext context = muleContextFactory.createMuleContext();

        assertMuleContextConfiguration(context);
        assertDefaults(context);
    }
View Full Code Here

        assertDefaults(context);
    }

    public void testCreateMuleContextConfigurationBuilder() throws Exception
    {
        MuleContext context = muleContextFactory.createMuleContext(new TestConfigurationBuilder());

        assertMuleContextConfiguration(context);
        assertConfigurationBuilder1Objects(context);
        assertNoDefaults(context);
    }
View Full Code Here

        List<ConfigurationBuilder> configBuilders = new ArrayList<ConfigurationBuilder>();
        configBuilders.add(new TestConfigurationBuilder());
        configBuilders.add(new TestConfigurationBuilder2());

        TestMuleContextBuilder muleContextBuilder = new TestMuleContextBuilder();
        MuleContext context = muleContextFactory.createMuleContext(configBuilders, muleContextBuilder);

        assertCustomMuleContext(context);
        assertConfigurationBuilder1Objects(context);
        assertConfigurationBuilder2Objects(context);
        assertNoDefaults(context);
View Full Code Here

    }

    public void testCreateMuleContextMuleContextBuilder() throws Exception
    {
        TestMuleContextBuilder muleContextBuilder = new TestMuleContextBuilder();
        MuleContext context = muleContextFactory.createMuleContext(new SimpleConfigurationBuilder(null), muleContextBuilder);

        assertCustomMuleContext(context);
        assertNoDefaults(context);
    }
View Full Code Here

    }

    public void testCreateMuleContextConfigurationBuilderMuleContextBuilder() throws Exception
    {
        TestMuleContextBuilder muleContextBuilder = new TestMuleContextBuilder();
        MuleContext context = muleContextFactory.createMuleContext(new TestConfigurationBuilder2(),
            muleContextBuilder);

        assertCustomMuleContext(context);
        assertConfigurationBuilder2Objects(context);
        assertNoDefaults(context);
View Full Code Here

        assertNoDefaults(context);
    }

    public void testCreateMuleContextString() throws Exception
    {
        MuleContext context = null;
        try
        {
            context = muleContextFactory.createMuleContext("log4j.properties");
        }
        catch (ConfigurationException e)
View Full Code Here

    {
        Properties properties = new Properties();
        properties.put("testKey1", "testValue1");
        properties.put("testKey2", "testValue2");

        MuleContext context = null;
        try
        {
            context = muleContextFactory.createMuleContext("log4j.properties", properties);
        }
        catch (ConfigurationException e)
View Full Code Here

    {
        Properties properties = new Properties();
        properties.put("testKey3", "testValue3");
        properties.put("testKey4", "testValue4");

        MuleContext context = muleContextFactory.createMuleContext(new TestConfigurationBuilder(), properties);

        assertMuleContextConfiguration(context);
        assertConfigurationBuilder1Objects(context);

        assertEquals("testValue3", context.getRegistry().lookupObject("testKey3"));
        assertEquals("testValue4", context.getRegistry().lookupObject("testKey4"));

        assertNoDefaults(context);
    }
View Full Code Here

        @Override
        public MuleContext buildMuleContext()
        {
            MuleContextLifecycleManager manager = getLifecycleManager();

            MuleContext context = new TestMuleContext(getMuleConfiguration(), getWorkManager(),
                getWorkListener(), manager, getNotificationManager());
            manager.setMuleContext(context);
            return context;
        }
View Full Code Here

TOP

Related Classes of org.mule.api.MuleContext

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.