Package org.apache.cxf

Examples of org.apache.cxf.BusFactory.createBus()


    public static Bus createStaticBus() throws Exception {
        if (defaultConfigFileName != null) {
            System.setProperty("cxf.config.file", defaultConfigFileName);
        }
        BusFactory bf = BusFactory.newInstance();
        staticBus = bf.createBus();
        BusFactory.setDefaultBus(staticBus);
        return staticBus;
    }
   
    @After
View Full Code Here


    protected IMocksControl control;
    protected DeliveryChannel channel;
    @Before
    public void setUp() {
        BusFactory bf = BusFactory.newInstance();
        bus = bf.createBus();
        BusFactory.setDefaultBus(bus);
        control = EasyMock.createNiceControl();
    }
   
    @After
View Full Code Here

        //
        // Just instantiate the Bus; services will be instantiated
        // and published automatically through Spring
        //
        final BusFactory factory = BusFactory.newInstance();
        Bus bus = factory.createBus();
        setBus(bus);
        BusFactory.setDefaultBus(bus);
        BusFactory.setThreadDefaultBus(bus);
    }
View Full Code Here

            BusFactory factory = new CXFBusFactory() {
                public Bus createBus(Map<Class, Object> e, Map<String, Object> properties) {
                    return new ExtensionManagerBus(e, properties, this.getClass().getClassLoader());
                }
            };
            Bus bus = factory.createBus();
            assertNotNullExtensions(bus);
        } finally {
            Thread.currentThread().setContextClassLoader(origClassLoader);
        }
    }
View Full Code Here

     * @throws Exception
     */
    @Test
    public void testDefaultBusConstruction() throws Exception {
        BusFactory factory = new CXFBusFactory();
        Bus bus = factory.createBus();
        assertNotNullExtensions(bus);
    }



View Full Code Here

    protected NMRTransportFactory nmrTransportFactory;
   
    @Before
    public void setUp() {
        BusFactory bf = BusFactory.newInstance();
        bus = bf.createBus();
        BusFactory.setDefaultBus(bus);
        nmrTransportFactory = new NMRTransportFactory();
        nmrTransportFactory.setBus(bus);
        nmrTransportFactory.registerWithBindingManager();
        control = EasyMock.createNiceControl();
View Full Code Here

        if (getCamelContext() instanceof SpringCamelContext) {
            SpringCamelContext springCamelContext = (SpringCamelContext)getCamelContext();
            ApplicationContext applicationContext = springCamelContext.getApplicationContext();
            busFactory = new org.apache.cxf.bus.spring.SpringBusFactory(applicationContext);
        }
        return busFactory.createBus();
       
    }
   
    /**
     *
 
View Full Code Here

        public void setApplicationContext(ApplicationContext ctx) throws BeansException {
            if (getBus() == null) {
                // Don't relate on the DefaultBus
                BusFactory factory = new SpringBusFactory(ctx);
                Bus bus = factory.createBus()
                BusWiringBeanFactoryPostProcessor.updateBusReferencesInContext(bus, ctx);
                setBus(bus);
            }
        }
View Full Code Here

       
        public void setApplicationContext(ApplicationContext ctx) throws BeansException {
            if (getBus() == null) {
                // Don't relate on the DefaultBus
                BusFactory factory = new SpringBusFactory(ctx);
                Bus bus = factory.createBus();   
                BusWiringBeanFactoryPostProcessor.updateBusReferencesInContext(bus, ctx);
                setBus(bus);
            }
        }
View Full Code Here

        public void setApplicationContext(ApplicationContext ctx) throws BeansException {
            applicationContext = ctx;
            if (getBus() == null) {
                // Don't relate on the DefaultBus
                BusFactory factory = new SpringBusFactory(ctx);
                Bus bus = factory.createBus();              
                setBus(bus);
            }
            BusWiringBeanFactoryPostProcessor.updateBusReferencesInContext(getBus(), ctx);
        }
       
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.