Package org.apache.cxf.wsdl11

Examples of org.apache.cxf.wsdl11.WSDLServiceFactoryImpl


     * @throws WSDLException
     */
    public Definition getWSDLDefinition(Server server) throws WSDLException {
        Service service = server.getEndpoint().getService();

        ServiceWSDLBuilder wsdlBuilder = new ServiceWSDLBuilder(bus, service.getServiceInfos().get(0));
        wsdlBuilder.setUseSchemaImports(false);
        return wsdlBuilder.build();
    }
View Full Code Here


        try {
            Writer os = new FileWriterUtil(file.getParent(),
                                           getOutputStreamCreator()).getWriter(file, "UTF-8");
            WSDLWriter wsdlWriter = WSDLFactory.newInstance().newWSDLWriter();

            ServiceWSDLBuilder builder = new ServiceWSDLBuilder(getBus(), getServiceModel());
            builder.setUseSchemaImports(this.allowImports());

            String name = file.getName();
            if (name.endsWith(".wsdl")) {
                name = name.substring(0, name.lastIndexOf(".wsdl"));
            }
            builder.setBaseFileName(name);
            Map<String, SchemaInfo> imports = new HashMap<String, SchemaInfo>();
            def = builder.build(imports);
            wsdlWriter.writeWSDL(def, os);
            os.close();

            if (def.getImports().size() > 0) {
                for (Import wsdlImport : WSDLDefinitionBuilder.getImports(def)) {
View Full Code Here

                smp = CastUtils.cast((Map<?, ?>)endpointInfo.getService()
                                    .getProperty(SCHEMAS_KEY));
            }
           
            if (!mp.containsKey("")) {
                ServiceWSDLBuilder builder =
                    new ServiceWSDLBuilder(bus, endpointInfo.getService());

                builder.setUseSchemaImports(
                     MessageUtils.getContextualBoolean(message, WSDL_CREATE_IMPORTS, false));
               
                // base file name is ignored if createSchemaImports == false!
                builder.setBaseFileName(endpointInfo.getService().getName().getLocalPart());
               
                Definition def = builder.build(new HashMap<String, SchemaInfo>());

                mp.put("", def);
                updateDefinition(bus, def, mp, smp, base, endpointInfo, "");
            }
           
View Full Code Here

       
       
        Server s = factory.create();

        try {
            ServiceWSDLBuilder builder = new ServiceWSDLBuilder(bus,
                                                                s.getEndpoint().getService()
                                                                    .getServiceInfos());
            Definition def = builder.build();
            WSDLWriter wsdlWriter = bus.getExtension(WSDLManager.class)
                .getWSDLFactory().newWSDLWriter();
            def.setExtensionRegistry(bus.getExtension(WSDLManager.class).getExtensionRegistry());
            Element wsdl = wsdlWriter.getDocument(def).getDocumentElement();
           
View Full Code Here

       
       
        Server s = factory.create();

        try {
            ServiceWSDLBuilder builder = new ServiceWSDLBuilder(bus,
                                                                s.getEndpoint().getService()
                                                                    .getServiceInfos());
            Definition def = builder.build();
            WSDLWriter wsdlWriter = bus.getExtension(WSDLManager.class)
                .getWSDLFactory().newWSDLWriter();
            def.setExtensionRegistry(bus.getExtension(WSDLManager.class).getExtensionRegistry());
            Element wsdl = wsdlWriter.getDocument(def).getDocumentElement();
           
View Full Code Here

    public void getWsdl(Request request, Response response) throws Exception {
        WSDLWriter wsdlWriter = WSDLFactory.newInstance().newWSDLWriter();

        EndpointInfo ei = this.destination.getEndpointInfo();

        Definition def = new ServiceWSDLBuilder(ei.getService()).build();

        /* FIXME: this doesn't quite work yet
        Port port = def.getService(ei.getService().getName()).getPort(ei.getName().getLocalPart());
        List<?> exts = port.getExtensibilityElements();
        if (exts.size() > 0) {
View Full Code Here

                                    .getProperty(WSDLQueryHandler.class.getName()
                                                 + ".Schemas"));
            }
           
            if (!mp.containsKey("")) {
                Definition def = new ServiceWSDLBuilder(bus, endpointInfo.getService()).build();

                mp.put("", def);
                updateDefinition(def, mp, smp, base, endpointInfo);
            }
           
View Full Code Here

                                    .getProperty(WSDLQueryHandler.class.getName()
                                                 + ".Schemas"));
            }
           
            if (!mp.containsKey("")) {
                Definition def = new ServiceWSDLBuilder(bus, endpointInfo.getService()).build();

                mp.put("", def);
                updateDefinition(def, mp, smp, base, endpointInfo);
            }
           
View Full Code Here

                                    .getProperty(WSDLQueryHandler.class.getName()
                                                 + ".Schemas"));
            }
           
            if (!mp.containsKey("")) {
                Definition def = new ServiceWSDLBuilder(bus, endpointInfo.getService()).build();
                mp.put("", def);
                updateDefinition(def, mp, smp, base, endpointInfo);
            }
           
           
View Full Code Here

    public void getWsdl(Request request, Response response) throws Exception {
        WSDLWriter wsdlWriter = WSDLFactory.newInstance().newWSDLWriter();

        EndpointInfo ei = this.destination.getEndpointInfo();

        Definition def = new ServiceWSDLBuilder(ei.getService()).build();
       
        QName serviceName = ei.getService().getName();
        String portName = ei.getName().getLocalPart();
       
        updateServices(serviceName, portName, def, request);
View Full Code Here

TOP

Related Classes of org.apache.cxf.wsdl11.WSDLServiceFactoryImpl

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.