Package xsul5.wsdl

Examples of xsul5.wsdl.WsdlPortTypeOperation


      while (iterator.hasNext()) {
        WsdlPortType portType = iterator.next();
        Iterator<WsdlPortTypeOperation> operations = portType
            .operations().iterator();
        while (operations.hasNext()) {
          WsdlPortTypeOperation operation = operations.next();
          WsdlMessagePart leadHeaderPart = new WsdlMessagePart(
              LEAD_HEADER);
          leadHeaderPart.setName(LEAD_HEADER);
          // we hand set this element to xml because when you use the
          // API it doent add the namespace correctly
          leadHeaderPart.xml().setAttributeValue(ELEMENT,
              LC_CONTEXT);

          wsdl.getMessage(
              operation.getInput().getMessage().getLocalPart())
              .addPart(leadHeaderPart);
        }
      }

      Iterator<WsdlBinding> bindingItr = wsdl.bindings().iterator();
View Full Code Here


  private QName findInputMessaQname(
      WsdlBindingOperation wsdlBindingOperation, WsdlDefinitions wsdl) {
    String operationName = wsdlBindingOperation.getName();
    WsdlPortType portType = wsdl.getPortType(wsdlBindingOperation
        .getBinding().getPortType().getLocalPart());
    WsdlPortTypeOperation operation = portType.getOperation(operationName);
    QName message = operation.getInput().getMessage();
    return message;
  }
View Full Code Here

            Iterator<WsdlPortType> iterator = wsdl.portTypes().iterator();
            while (iterator.hasNext()) {
                WsdlPortType portType = iterator.next();
                Iterator<WsdlPortTypeOperation> operations = portType.operations().iterator();
                while (operations.hasNext()) {
                    WsdlPortTypeOperation operation = operations.next();
                    WsdlMessagePart leadHeaderPart = new WsdlMessagePart(LEAD_HEADER);
                    leadHeaderPart.setName(LEAD_HEADER);
                    // we hand set this element to xml because when you use the
                    // API it doent add the namespace correctly
                    leadHeaderPart.xml().setAttributeValue(ELEMENT, LC_CONTEXT);

                    wsdl.getMessage(operation.getInput().getMessage().getLocalPart()).addPart(leadHeaderPart);
                }
            }

            Iterator<WsdlBinding> bindingItr = wsdl.bindings().iterator();
            while (bindingItr.hasNext()) {
View Full Code Here

    }

    private QName findInputMessaQname(WsdlBindingOperation wsdlBindingOperation, WsdlDefinitions wsdl) {
        String operationName = wsdlBindingOperation.getName();
        WsdlPortType portType = wsdl.getPortType(wsdlBindingOperation.getBinding().getPortType().getLocalPart());
        WsdlPortTypeOperation operation = portType.getOperation(operationName);
        QName message = operation.getInput().getMessage();
        return message;
    }
View Full Code Here

    }

    private WsdlPortType createPortType(String portTypeName, String operationName, WsdlMessage inputMessage,
            WsdlMessage outputMessage) {
        WsdlPortType portType = this.definitions.addPortType(portTypeName);
        WsdlPortTypeOperation operation = portType.addOperation(operationName);
        if (inputMessage != null) {
            operation.setInput(inputMessage);
        }
        if (outputMessage != null) {
            operation.setOutput(outputMessage);
        }
        return portType;
    }
View Full Code Here

        Iterator<String> iterator = wsdls.keySet().iterator();
        while (iterator.hasNext()) {
            String key = (String) iterator.next();
            WsdlDefinitions wsdlDefinitions = wsdls.get(key);
            WsdlPortType pType = wsdlDefinitions.getPortType(portType.getLocalPart());
            WsdlPortTypeOperation operation = null;
            if (null != pType && null != (operation = pType.getOperation(opName))) {

                if (input) {
                    WsdlPortTypeInput messageRef = operation.getInput();
                    if (null != messageRef && null != messageRef.getMessage()) {
                        WsdlMessage message = wsdlDefinitions.getMessage(messageRef.getMessage().getLocalPart());
                        if (null != message) {
                            return new QName(wsdlDefinitions.getTargetNamespace(), message.getName(), key);
                        }
                    }
                } else {
                    xsul5.wsdl.WsdlPortTypeOutput messageRef = operation.getOutput();
                    if (null != messageRef && null != messageRef.getMessage()) {
                        WsdlMessage message = wsdlDefinitions.getMessage(messageRef.getMessage().getLocalPart());
                        if (null != message) {
                            return new QName(wsdlDefinitions.getTargetNamespace(), message.getName(), key);
                        }
View Full Code Here

                    while (keys.hasNext()) {
                        String key = keys.next();
                        WsdlDefinitions wsdl = wsdls.get(key);
                        WsdlPortType portType = wsdl.getPortType(portTypeName);
                        if (null != portType) {
                            WsdlPortTypeOperation wsdlOperation = portType.getOperation(operation);
                            WsdlMessagePart part = wsdl
                                    .getMessage(wsdlOperation.getInput().getMessage().getLocalPart()).parts()
                                    .iterator().next();
                            XmlElement childElement = container.addElement(part.getElement().getLocalPart());
                            Iterator<GpelAssignCopy> copyItr = assign.copyOperations().iterator();
                            while (copyItr.hasNext()) {
                                GpelAssignCopy copyItm = copyItr.next();
                                childElement.addElement(getElementName(copyItm.getTo().getQuery()));
                                if (messagePartName == null) {
                                    messagePartName = copyItm.getTo().xml().attributeValue(PART_STR);
                                }
                            }
                            break;
                        }
                    }
                } else {
                    // reply

                    WsdlPortType portType = workflowWSDL.getPortType(portTypeName);
                    if (null != portType) {
                        WsdlPortTypeOperation wsdlOperation = portType.getOperation(operation);
                        WsdlMessagePart part = workflowWSDL
                                .getMessage(wsdlOperation.getOutput().getMessage().getLocalPart()).parts().iterator()
                                .next();
                        XmlElement childElement = container.addElement(part.getElement().getLocalPart());
                        Iterator<GpelAssignCopy> copyItr = assign.copyOperations().iterator();
                        while (copyItr.hasNext()) {
                            GpelAssignCopy copyItm = copyItr.next();
View Full Code Here

        }
        parsePortType(portType);
    }

    private void parsePortType(WsdlPortType portType) throws ComponentException {
        WsdlPortTypeOperation operation = portType.getOperation(this.operationName);
        if (operation == null) {
            throw new ComponentException("Operation, " + this.operationName + " is not defined.");
        }
        parseOperation(operation);
    }
View Full Code Here

            XmlElement eventElement = event.getEvent();
            XmlElement result = eventElement.element(MonitorUtil.REQUEST);
            XmlElement body = result.element(MonitorUtil.BODY);
            XmlElement soapBody = body.element(XmlConstants.S_BODY);
            WsdlPortType firstPortType;
            WsdlPortTypeOperation wsdlPortTypeOperation;
      try {
        wsdlPortTypeOperation = WSDLUtil.getFirstOperation(this.modifiedWorkflow.getWorkflowWSDL());
      } catch (ComponentException e) {
        throw new MonitorException(e);
      }
            XmlElement part = soapBody
                    .element(wsdlPortTypeOperation.getName());
            XmlElement parameter = part.element(nodeID);
            // TODO support complex type.
            String value = parameter.requiredText();
            return value;
        }
View Full Code Here

            // TODO null check
            XmlElement eventElement = event.getEvent();
            XmlElement result = eventElement.element(MonitorUtil.REQUEST);
            XmlElement body = result.element(MonitorUtil.BODY);
            XmlElement soapBody = body.element(XmlConstants.S_BODY);
            WsdlPortTypeOperation wsdlPortTypeOperation;
            try {
                wsdlPortTypeOperation = WSDLUtil.getFirstOperation(this.modifiedWorkflow.getWorkflowWSDL());
            } catch (UtilsException e) {
                throw new MonitorException(e);
            }
            XmlElement part = soapBody.element(wsdlPortTypeOperation.getName());
            XmlElement parameter = part.element(nodeID);
            // TODO support complex type.
            String value = parameter.requiredText();
            return value;
        }
View Full Code Here

TOP

Related Classes of xsul5.wsdl.WsdlPortTypeOperation

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.