Package org.apache.cxf.frontend

Examples of org.apache.cxf.frontend.ServerFactoryBean.create()


        return serverFactoryBean.create();
    }

    public Server createService(Class serviceClass, Object serviceBean, String address, QName name) {
        ServerFactoryBean sf = createServiceFactory(serviceClass, serviceBean, address, name, null);
        return sf.create();
    }

    public Server createService(Class serviceClass, Object serviceBean, String address,
                                AegisDatabinding binding) {
        ServerFactoryBean sf = createServiceFactory(serviceClass, serviceBean, address, null, binding);
View Full Code Here


    }

    public Server createService(Class serviceClass, Object serviceBean, String address,
                                AegisDatabinding binding) {
        ServerFactoryBean sf = createServiceFactory(serviceClass, serviceBean, address, null, binding);
        return sf.create();
    }

    protected ServerFactoryBean createServiceFactory(Class serviceClass, Object serviceBean, String address,
                                                     QName name, AegisDatabinding binding) {
        ServerFactoryBean sf = new ServerFactoryBean();
View Full Code Here

       
        ServerFactoryBean sf2 = new ServerFactoryBean();
        sf2.setAddress("http://localhost:9167/SimpleEcho");
        sf2.setDataBinding(new AegisDatabinding());
        sf2.setServiceBean(new Echo());
        server = sf2.create();
        // turn off nanny in URIMappingInterceptor
        server.getEndpoint()
            .getService().put(AbstractInDatabindingInterceptor.NO_VALIDATE_PARTS, Boolean.TRUE);
    }
   
View Full Code Here

        svrBean.setTransportId("http://schemas.xmlsoap.org/soap/http");
        svrBean.setServiceBean(new HelloServiceImpl());
        svrBean.setServiceClass(HelloService.class);       
        svrBean.setBus(getBus());
       
        svrBean.create();
       
        ClientProxyFactoryBean proxyFactory = new ClientProxyFactoryBean();
        ClientFactoryBean clientBean = proxyFactory.getClientFactoryBean();
        clientBean.setAddress("http://localhost/Hello");
        clientBean.setTransportId("http://schemas.xmlsoap.org/soap/http");
View Full Code Here

        svrBean.setServiceName(new QName("http://apache.org/hello_world_doc_lit",
                                         "SOAPService"));
        svrBean.setWsdlLocation("testutils/hello_world_doc_lit.wsdl");
        svrBean.setBus(getBus());
       
        svrBean.create();
    }
}
View Full Code Here

        Map<String, Object> props = new HashMap<String, Object>();
        props.put("test", "test");
        serviceFactory.setProperties(props);
        svrBean.setProperties(props);
       
        Server server = svrBean.create();
        assertNotNull(server);
        Map<QName, Endpoint> eps = service.getEndpoints();
        assertEquals(1, eps.size());
       
        Endpoint ep = eps.values().iterator().next();
View Full Code Here

        // use full parameter names.
        sf.setServiceClass(FlatArrayServiceInterface.class);
        sf.setServiceBean(service);
        sf.setAddress("local://FlatArray");
        sf.setDataBinding(new AegisDatabinding());
        Server s = sf.create();
        s.getEndpoint().getInInterceptors().add(new LoggingInInterceptor());

        arrayWsdlDoc = getWSDLDocument("FlatArrayServiceInterface");
    }
View Full Code Here

        svrBean1.getInInterceptors().add(new AbstractPhaseInterceptor<Message>(Phase.USER_LOGICAL) {
            public void handleMessage(Message message) throws Fault {
                service1Invoked = true;
            }
        });
        svrBean1.create();
       
        ServerFactoryBean svrBean2 = new ServerFactoryBean();
        svrBean2.setAddress("http://localhost/Hello");
        svrBean2.setServiceClass(HelloService.class);
        svrBean2.setServiceBean(new HelloServiceImpl());
View Full Code Here

       
        SoapBindingConfiguration config = new SoapBindingConfiguration();
        config.setVersion(Soap12.getInstance());
        svrBean2.setBindingConfig(config);
       
        ServerImpl server2 = (ServerImpl)svrBean2.create();
       
        Destination d = server2.getDestination();
        MessageObserver mo = d.getMessageObserver();
        assertTrue(mo instanceof MultipleEndpointObserver);
       
View Full Code Here

        ServerFactoryBean svrFactory = new ServerFactoryBean();
        // we sure can't get a .class for the interface, can we?
        svrFactory.setServiceClass(impl.getClass());
        svrFactory.setAddress("http://localhost:9000/aegisgeneric");
        svrFactory.setServiceBean(impl);
        Server server = svrFactory.create();
        ServiceInfo serviceInfo = ((EndpointImpl)server.getEndpoint()).getEndpointInfo().getService();
        Collection<SchemaInfo> schemata = serviceInfo.getSchemas();
        BasicNameManager nameManager = BasicNameManager.newNameManager(serviceInfo);
        NamespacePrefixAccumulator prefixManager = new NamespacePrefixAccumulator(serviceInfo
            .getXmlSchemaCollection());
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.