Examples of WSDLService


Examples of org.apache.wsdl.WSDLService

        ///////////////////(4)Copy the Services///////////////////////////////

        Iterator serviceIterator = wsdl4JDefinition.getServices().values()
                .iterator();
        WSDLService wsdlService;
        Service wsdl4jService;
        while (serviceIterator.hasNext()) {
            wsdlService = this.wsdlComponentFactory.createService();
            wsdl4jService = (Service) serviceIterator.next();
            this.populateServices(wsdlService, wsdl4jService);
View Full Code Here

Examples of org.apache.wsdl.WSDLService

                targetNamespace);

        womDescription.addBinding(binding);

        //generating service
        WSDLService service = generateService(wsdlComponentFactory, womDescription, binding, serviceName);
        womDescription.addService(service);
        return womDescription;
    }
View Full Code Here

Examples of org.apache.wsdl.WSDLService

     * @return
     */
    public WSDLService generateService(WSDLComponentFactory wsdlComponentFactory,
                                       WSDLDescription womDescription,
                                       WSDLBinding binding, String ServiceName) {
        WSDLService service = wsdlComponentFactory.createService();
        service.setName(new QName(ServiceName));
        WSDLEndpoint endpoints = wsdlComponentFactory.createEndpoint();
        endpoints.setBinding(binding);
        endpoints.setName(new QName(ServiceName + PORT_NAME_SUFFIX));
        SOAPAddressImpl address = new SOAPAddressImpl();
        address.setLocationURI("http://127.0.0.1:8080/axis2/services/" + ServiceName)// ???
        endpoints.addExtensibilityElement(address);
        service.setEndpoint(endpoints);
        return service;
    }
View Full Code Here

Examples of org.apache.wsdl.WSDLService

        description = wsdlDesc;
//    ConfigurationContext configurationContext = configctx;
    }

    public AxisService buildAxisService(QName servicename, String endpointname, Options clientOptions) throws AxisFault {
        WSDLService service = findService(servicename);
        AxisService serviceDesc = new AxisService();

        //TODO we just pick first end point
        WSDLEndpoint endpoint = findEndpoint(null, service);
View Full Code Here

Examples of org.apache.wsdl.WSDLService

            return WSDLConstants.MEP_CONSTANT_IN_OUT;
        }
    }

    private WSDLService findService(QName serviceName) throws AxisFault {
        WSDLService service;

        if (serviceName == null) {
            Iterator services = description.getServices().values().iterator();

            if (services.hasNext()) {
View Full Code Here

Examples of org.apache.wsdl.WSDLService

public class PolicyUtil {

  public static void populatePolicy(WSDLDescription description,
      AxisService axisService) {
    WSDLService wsdlService = description.getService(new QName(axisService
        .getName()));
    populatePolicy(description, wsdlService, axisService);
  }
View Full Code Here

Examples of org.apache.wsdl.WSDLService

                Constants.URI_SOAP11_HTTP,
                "http://www.org.apache.axis2");
        womDescription.addBinding(binding);

        // generating axisService
        WSDLService service = generateService(wsdlComponentFactory, binding,
                axisService.getName(), url);
        womDescription.addService(service);
        return womDescription;
    }
View Full Code Here

Examples of org.apache.wsdl.WSDLService

    }

    private WSDLService generateService(
            WSDLComponentFactory wsdlComponentFactory, WSDLBinding binding,
            String ServiceName, String [] URL) {
        WSDLService service = wsdlComponentFactory.createService();
        service.setName(new QName(ServiceName));

        /*
           * Adding policies defined in services.xml
           */

        ArrayList policyElementList;
        PolicyInclude include;

        // Policies defined in Axis2.xml
        AxisDescription axisConfiguration = null;

        AxisDescription serviceGroup = axisService.getParent();
        if (serviceGroup != null) {
            axisConfiguration = serviceGroup.getParent();
        }

        if (axisConfiguration != null) {
            include = axisConfiguration.getPolicyInclude();
            policyElementList = include
                    .getPolicyElements(PolicyInclude.AXIS_POLICY);
            addPolicyAsExtElements(womDescription, policyElementList, service,
                    include);
        }

        for (int i = 0; i < URL.length; i++) {
            String epr = URL[i];
            WSDLEndpoint endpoints = wsdlComponentFactory.createEndpoint();
            endpoints.setBinding(binding);
            endpoints.setName(new QName(ServiceName + "PortType" + i));
            SOAPAddressImpl address = new SOAPAddressImpl();
            address.setLocationURI(epr);
            endpoints.addExtensibilityElement(address);
            service.setEndpoint(endpoints);
        }
        return service;
    }
View Full Code Here

Examples of org.apache.wsdl.WSDLService

        ///////////////////(4)Copy the Services///////////////////////////////

        Iterator serviceIterator = wsdl4JDefinition.getServices().values()
                .iterator();
        WSDLService wsdlService;
        Service wsdl4jService;
        while (serviceIterator.hasNext()) {
            wsdlService = this.wsdlComponentFactory.createService();
            wsdl4jService = (Service) serviceIterator.next();
            this.populateServices(wsdlService, wsdl4jService);
View Full Code Here

Examples of org.apache.wsdl.WSDLService

     */
    private void writeService(WSDLDescription wsdlDescription) throws IOException, XMLStreamException {
        Map serviceMap = wsdlDescription.getServices();
        if (serviceMap != null && !serviceMap.isEmpty()) {
            Iterator serviceIterator = serviceMap.values().iterator();
            WSDLService service;
            while (serviceIterator.hasNext()) {
                service = (WSDLService) serviceIterator.next();
                writer.writeStartElement(defaultWSDLPrefix, "service", WSDL1_1_NAMESPACE_URI);
                writer.writeAttribute("name", service.getName().getLocalPart());
                handleExtensibiltyElements(service.getExtensibilityElements());
                //wrtie the porttypes
                Map endPointMap = service.getEndpoints();
                if (endPointMap != null && !endPointMap.isEmpty()) {
                    Iterator it = endPointMap.values().iterator();
                    while (it.hasNext()) {
                        writePort((WSDLEndpoint) it.next());
                    }
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.