Package javax.wsdl

Examples of javax.wsdl.BindingInput


    SOAPOperation soapOperation = new SOAPOperationImpl() ;
    soapOperation.setSoapActionURI(serviceInfo.getResponseAction()) ;
    bop.addExtensibilityElement(soapOperation) ;
   
    if (op.getInput() != null) {
      BindingInput binput = def.createBindingInput();
      bop.setBindingInput(binput);
      SOAPBodyImpl soapBody = new SOAPBodyImpl();
      soapBody.setUse("literal");
      binput.setName(serviceInfo.getRequestName()) ;
      binput.addExtensibilityElement(soapBody);
    }
    if (op.getOutput() != null) {
      BindingOutput boutput = def.createBindingOutput();
      bop.setBindingOutput(boutput);
      SOAPBodyImpl soapBody = new SOAPBodyImpl();
View Full Code Here


        BindingOutput bindingOutput = def.createBindingOutput();
        bindingOutput.addExtensibilityElement(soapBody);
        bindingOperation.setBindingOutput(bindingOutput);

        BindingInput bindingInput = def.createBindingInput();
        bindingInput.addExtensibilityElement(soapBody);
        bindingOperation.setBindingInput(bindingInput);

        SOAPOperation soapOperation = new SOAPOperationImpl();
        // soapAction should be set to the location of the SOAP URI, or Visual Studio won't construct the correct SOAP message
        soapOperation.setSoapActionURI(locationURI);
View Full Code Here

                    " for op ",
                    operation.getName());
                String opStyle = soapOperation.getStyle();

                // try to get soap:body for input message
                BindingInput binpt = bop.getBindingInput();
                SOAPBody soapInputBody =
                    (SOAPBody) getExtElem(binpt,
                        SOAPBody.class,
                        binpt.getExtensibilityElements());
                if (soapInputBody != null) {
                    String namespaceURI = soapInputBody.getNamespaceURI();

                    Trc.event(
                        this,
                        "setting namespace ",
                        namespaceURI,
                        " for op ",
                        operation.getName());

                    operation.setInputNamespace(namespaceURI);
                    String use = soapInputBody.getUse();
                    operation.setInputUse(use);

                    List encodingStyles = soapInputBody.getEncodingStyles();
                    if (encodingStyles != null) {
                        if (encodingStyles.size() == 0) {
                        }
                        operation.setInputEncodingStyle(
                            (String) encodingStyles.get(0));
                        // quietly ignore if encodingStyles.size() > 1 ...
                    }
                    List parts = soapInputBody.getParts();
                    if (parts != null)
                        operation.setPartNames(parts);
                }

                SOAPHeader soapHeader =
                    (SOAPHeader) getExtElem(binpt,
                        SOAPHeader.class,
                        binpt.getExtensibilityElements());
                if (soapHeader != null) {
                    throw new WSIFException(
                        "not supported input soap:header " + soapHeader);
                }

                List inJmsProps =
                    getExtElems(
                        binpt,
                        JMSProperty.class,
                        binpt.getExtensibilityElements());
                if (inJmsProps != null && inJmsProps.size() > 0) {
                    if (st instanceof SOAPJMSConnection)
                        operation.setInputJmsProperties(inJmsProps);
                    else
                        throw new WSIFException("jms:properties found in non-jms binding");
                }

                List inJmsPropVals =
                    getExtElems(
                        binpt,
                        JMSPropertyValue.class,
                        binpt.getExtensibilityElements());
                if (inJmsPropVals != null && inJmsPropVals.size() > 0) {
                    if (st instanceof SOAPJMSConnection)
                        operation.addInputJmsPropertyValues(inJmsPropVals);
                    else
                        throw new WSIFException("jms:propertyValue found in non-jms binding");
View Full Code Here

    } catch (WSIFException ex) {
      Trc.ignoredException(ex);
    }

    try {
      BindingInput bi = fieldBindingOperation.getBindingInput();
      value = (bi == null) ? null : bi.getName();
      if (value != null && value.length() > 0) {
        jmsDest.setProperty(WSIFConstants.JMS_PROP_INPUT_NAME, value);
      }
    } catch (WSIFException ex) {
      Trc.ignoredException(ex);
View Full Code Here

   *                                encodingStyle="uri-list"? namespace="uri"?/>*
   *          <soap:header>                               
   *      </input>
   */
  private void parseBindingInput() throws WSIFException {
    BindingInput bindinginput = bindingOperation.getBindingInput();
    List inExtElems = bindinginput.getExtensibilityElements();
   
    SOAPBody inSoapBody =
      (SOAPBody) wsifPort.getExtElem(
        bindinginput,
        javax.wsdl.extensions.soap.SOAPBody.class,
        inExtElems);
    if (inSoapBody != null) {
      this.inputSOAPParts = parseSoapBody(inSoapBody, true);
    }

    MIMEMultipartRelated inMimeMultipart =
      (MIMEMultipartRelated) wsifPort.getExtElem(
        bindinginput,
        MIMEMultipartRelated.class,
        inExtElems);

    if (inSoapBody != null && inMimeMultipart != null) {
      throw new WSIFException(
        "In a binding operation that contains a mime:multipartRelated, "
          + "a soap:body was found that was not in a mime:part. "
          + "OperationName="
          + getName());
    }
    if (inSoapBody == null && inMimeMultipart == null) {
      throw new WSIFException(
        "binding operation input must contain either a soap:body " +
        "or a mime:multipartRelated element. "
          + "OperationName="
          + getName());
    }

    if (inMimeMultipart != null) {
      parseMimeMultipart(inMimeMultipart, true);
    }

    MIMEMimeXml inMimeMimeXml =
      (MIMEMimeXml) wsifPort.getExtElem(
        bindinginput,
        MIMEMimeXml.class,
        inExtElems);
    if (inMimeMimeXml != null)
      throw new WSIFException(
        "WSIF does not support mime:mimeXml. Operation="
          + getName());

    parseSOAPHeaderElement(bindinginput);

    List inJmsProps =
      wsifPort.getExtElems(
        bindinginput,
        JMSProperty.class,
        bindinginput.getExtensibilityElements());
    if (inJmsProps != null && inJmsProps.size() > 0) {
      if (wsifPort.isTransportJMS())
        setInputJmsProperties(inJmsProps);
      else
        throw new WSIFException("jms:property found in non-jms binding");
    }

    List inJmsPropVals =
      wsifPort.getExtElems(
        bindinginput,
        JMSPropertyValue.class,
        bindinginput.getExtensibilityElements());
    if (inJmsPropVals != null && inJmsPropVals.size() > 0) {
      if (wsifPort.isTransportJMS())
        addInputJmsPropertyValues(inJmsPropVals);
      else
        throw new WSIFException("jms:propertyValue found in non-jms binding");
View Full Code Here

                str = "bindingOperation(UNNAMED";
            else
                str = "bindingOperation(" + bo.getName();
        } else if (o instanceof BindingInput) {
            found = true;
            BindingInput bi = (BindingInput) o;
            if (bi == null)
                str = "bindingInput(NULL)";
            else if (bi.getName() == null)
                str = "bindingInput(UNNAMED";
            else
                str = "bindingInput(" + bi.getName();
        } else if (o instanceof BindingOutput) {
            found = true;
            BindingOutput bo = (BindingOutput) o;
            if (bo == null)
                str = "bindingOutput(NULL)";
View Full Code Here

    }

    protected String getInputMessageName() throws WSIFException {
        Trc.entry(this);
        if (fieldInputMessageName == null) {
            BindingInput bindingInputModel =
                fieldBindingOperationModel.getBindingInput();
            if (bindingInputModel != null) {
                fieldInputMessageName = bindingInputModel.getName();
            }
        }
        Trc.exit(fieldInputMessageName);
        return fieldInputMessageName;
    }
View Full Code Here

                        + name
                        + " binding has not style attribute");
            }

            // try to get soap:body for input message
            BindingInput binpt = bop.getBindingInput();
            SOAPBody soapInputBody =
                (SOAPBody) getExtElem(binpt, SOAPBody.class, binpt.getExtensibilityElements());
            if (soapInputBody != null) {
                String namespaceURI = soapInputBody.getNamespaceURI();
               
                if (Trc.ON)
                    Trc.event(
                        this,
                        "setting namespace "
                            + namespaceURI
                            + " for op "
                            + opInst.getName());
                opInst.setInputNamespace(namespaceURI);
                String use = soapInputBody.getUse();
                if (!"encoded".equals(use)) {
                    throw new WSIFException("unsupported use " + use + " in " + soapOperation);
                }
                List encodingStyles = soapInputBody.getEncodingStyles();
                if (encodingStyles != null) {
                    if (encodingStyles.size() == 0) {
                    }
                    opInst.setInputEncodingStyle((String) encodingStyles.get(0));
                    // quietly ignore if encodingStyles.size() > 1 ...
                }
                List parts = soapInputBody.getParts();
                if (parts != null) {
                    opInst.setPartNames(parts);
                }
            }
            SOAPHeader soapHeader =
                (SOAPHeader) getExtElem(binpt,
                    SOAPHeader.class,
                    binpt.getExtensibilityElements());
            if (soapHeader != null) {
                throw new WSIFException("not supported input soap:header " + soapHeader);
            }

            // try to get soap:body for output message
View Full Code Here

       
    }

    protected void buildBindingInput(Definition def, BindingOperation bindingOperation,
                                         BindingMessageInfo bindingMessageInfo) {
        BindingInput bindingInput = null;
        if (bindingMessageInfo != null) {
            bindingInput = def.createBindingInput();
            bindingInput.setName(bindingMessageInfo.getMessageInfo().getName().getLocalPart());
            bindingOperation.setBindingInput(bindingInput);
            addExtensibilityAttributes(bindingInput, bindingMessageInfo.getExtensionAttributes());
            addExtensibilityElements(bindingInput, getWSDL11Extensors(bindingMessageInfo));
        }
    }
View Full Code Here

            input.setName(msgName);
            msg.setUndefined(false);
            operation.setInput(input);
            definition.addMessage(msg);
           
            BindingInput bindingInput = definition.createBindingInput();
            bindingInput.setName(msgName);       
            bindingOperation.setBindingInput(bindingInput);
           
            inputMessage = msg;
        }
       
View Full Code Here

TOP

Related Classes of javax.wsdl.BindingInput

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.