Package org.jboss.ws.metadata.wsdl

Examples of org.jboss.ws.metadata.wsdl.WSDLBindingOperation


                  exceptionMapping.setWsdlMessage(fault.getName());
                  jwm.addExceptionMappings(exceptionMapping);
               }
            }

            WSDLBindingOperation bindingOperation = HeaderUtil.getWSDLBindingOperation(wsdlDefinitions, op);
            if (bindingOperation != null)
            {
               constructHeaderJavaXmlTypeMapping(jwm, HeaderUtil.getSignatureHeaders(bindingOperation.getInputs()));
               constructHeaderJavaXmlTypeMapping(jwm, HeaderUtil.getSignatureHeaders(bindingOperation.getOutputs()));
            }

         }//end for
      }
   }
View Full Code Here


         if (Constants.WSDL20_PATTERN_IN_ONLY.equals(wsdlOperation.getPattern()))
            opMetaData.setOneWay(true);

         // Set the operation SOAPAction
         WSDLBinding wsdlBinding = wsdlDefinitions.getBindingByInterfaceName(wsdlInterface.getName());
         WSDLBindingOperation wsdlBindingOperation = wsdlBinding.getOperationByRef(opQName);
         if (wsdlBindingOperation != null)
            opMetaData.setSOAPAction(wsdlBindingOperation.getSOAPAction());
      }
   }
View Full Code Here

   private WSDLBindingMessageReference getBindingReference(WSDLInterfaceMessageReference reference)
   {
      WSDLInterfaceOperation wsdlOperation = reference.getWsdlOperation();
      WSDLInterface wsdlInterface = wsdlOperation.getWsdlInterface();
      WSDLBinding binding = wsdlInterface.getWsdlDefinitions().getBindingByInterfaceName(wsdlInterface.getName());
      WSDLBindingOperation bindingOperation = binding.getOperationByRef(wsdlOperation.getName());
      WSDLBindingMessageReference[] bindingReferences;

      if (reference instanceof WSDLInterfaceOperationInput)
         bindingReferences = bindingOperation.getInputs();
      else
         bindingReferences = bindingOperation.getOutputs();

      if (bindingReferences.length > 1)
         throw new IllegalArgumentException("WSDl 1.1 only supports In-Only, and In-Out MEPS, more than reference input found");

      if (bindingReferences.length == 1)
View Full Code Here

      WSDLBindingOperation[] operations = binding.getOperations();
      Arrays.sort(operations);

      for (int i = 0; i < operations.length; i++)
      {
         WSDLBindingOperation operation = operations[i];
         QName interfaceName = operation.getWsdlBinding().getInterfaceName();

         WSDLInterface wsdlInterface = wsdl.getInterface(interfaceName);
         if (wsdlInterface == null)
            throw new WSException("WSDL Interface should not be null");
         WSDLInterfaceOperation interfaceOperation = wsdlInterface.getOperation(operation.getRef());

         buffer.append("<operation name='" + interfaceOperation.getName().getLocalPart() + "'>");
         String soapAction = (operation.getSOAPAction() != null ? operation.getSOAPAction() : "");
         appendUnknownExtensibilityElements(buffer, operation);
         buffer.append("<" + soapPrefix + ":operation soapAction=\"" + soapAction + "\"/>");

         WSDLBindingOperationInput[] inputs = operation.getInputs();
         if (inputs.length != 1)
            throw new WSException("WSDl 1.1 only supports In-Only, and In-Out MEPS.");

         buffer.append("<input>");
         appendUnknownExtensibilityElements(buffer, inputs[0]);
         appendSOAPBinding(buffer, wsdlInterface, operation, inputs);
         buffer.append("</input>");

         if (! Constants.WSDL20_PATTERN_IN_ONLY.equals(getBindingOperationPattern(operation)))
         {
            buffer.append("<output>");
            WSDLBindingOperationOutput[] outputs = operation.getOutputs();
            appendSOAPBinding(buffer, wsdlInterface, operation, outputs);
            buffer.append("</output>");
         }

         //Append faults
View Full Code Here

      log.trace("processBindingOperation: " + srcOperationName);

      WSDLInterface destInterface = destBinding.getInterface();
      String namespaceURI = destInterface.getName().getNamespaceURI();

      WSDLBindingOperation destBindingOperation = new WSDLBindingOperation(destBinding);
      QName refQName = new QName(namespaceURI, srcOperationName);
      destBindingOperation.setRef(refQName);
      processUnknownExtensibilityElements(srcBindingOperation, destBindingOperation);
      destBinding.addOperation(destBindingOperation);

      String opName = srcOperationName;
      WSDLInterfaceOperation destIntfOperation = destInterface.getOperation(opName);

      // Process soap:operation@soapAction, soap:operation@style
      List<ExtensibilityElement> extList = srcBindingOperation.getExtensibilityElements();
      for (ExtensibilityElement extElement : extList)
      {
         if (extElement instanceof SOAPOperation)
         {
            SOAPOperation soapOp = (SOAPOperation)extElement;
            destBindingOperation.setSOAPAction(soapOp.getSoapActionURI());
         }
         else if (extElement instanceof SOAP12Operation)
         {
            SOAP12Operation soapOp = (SOAP12Operation)extElement;
            destBindingOperation.setSOAPAction(soapOp.getSoapActionURI());
         }
      }

      BindingInput srcBindingInput = srcBindingOperation.getBindingInput();
      if (srcBindingInput != null)
View Full Code Here

/* 262 */       if ("http://www.w3.org/2004/08/wsdl/in-only".equals(wsdlOperation.getPattern())) {
/* 263 */         opMetaData.setOneWay(true);
/*     */       }
/*     */
/* 266 */       WSDLBinding wsdlBinding = wsdlDefinitions.getBindingByInterfaceName(wsdlInterface.getName());
/* 267 */       WSDLBindingOperation wsdlBindingOperation = wsdlBinding.getOperationByRef(opQName);
/* 268 */       if (wsdlBindingOperation != null)
/* 269 */         opMetaData.setSOAPAction(wsdlBindingOperation.getSOAPAction());
/*     */     }
/*     */   }
View Full Code Here

/* 1255 */     log.trace("processBindingOperation: " + srcOperationName);
/*      */
/* 1257 */     WSDLInterface destInterface = destBinding.getInterface();
/* 1258 */     String namespaceURI = destInterface.getName().getNamespaceURI();
/*      */
/* 1260 */     WSDLBindingOperation destBindingOperation = new WSDLBindingOperation(destBinding);
/* 1261 */     QName refQName = new QName(namespaceURI, srcOperationName);
/* 1262 */     destBindingOperation.setRef(refQName);
/* 1263 */     processUnknownExtensibilityElements(srcBindingOperation, destBindingOperation);
/* 1264 */     destBinding.addOperation(destBindingOperation);
/*      */
/* 1266 */     String opName = srcOperationName;
/* 1267 */     WSDLInterfaceOperation destIntfOperation = destInterface.getOperation(opName);
/*      */
/* 1270 */     List extList = srcBindingOperation.getExtensibilityElements();
/* 1271 */     for (ExtensibilityElement extElement : extList)
/*      */     {
/* 1273 */       if ((extElement instanceof SOAPOperation))
/*      */       {
/* 1275 */         SOAPOperation soapOp = (SOAPOperation)extElement;
/* 1276 */         destBindingOperation.setSOAPAction(soapOp.getSoapActionURI());
/*      */       }
/* 1278 */       else if ((extElement instanceof SOAP12Operation))
/*      */       {
/* 1280 */         SOAP12Operation soapOp = (SOAP12Operation)extElement;
/* 1281 */         destBindingOperation.setSOAPAction(soapOp.getSoapActionURI());
/*      */       }
/*      */     }
/*      */
/* 1285 */     BindingInput srcBindingInput = srcBindingOperation.getBindingInput();
/* 1286 */     if (srcBindingInput != null)
View Full Code Here

/* 158 */     for (WSDLInterfaceOperation wsdlOperation : wsdlInterface.getOperations())
/*     */     {
/* 160 */       QName opQName = wsdlOperation.getName();
/* 161 */       String opName = opQName.getLocalPart();
/*     */
/* 163 */       WSDLBindingOperation wsdlBindingOperation = wsdlOperation.getBindingOperation();
/* 164 */       if (wsdlBindingOperation == null) {
/* 165 */         this.log.warn("Could not locate binding operation for:" + opQName);
/*     */       }
/*     */
/* 169 */       String namespaceURI = wsdlBindingOperation.getNamespaceURI();
/* 170 */       if (namespaceURI != null) {
/* 171 */         opQName = new QName(namespaceURI, opName);
/*     */       }
/*     */
/* 174 */       String javaName = opName.substring(0, 1).toLowerCase() + opName.substring(1);
/* 175 */       ServiceEndpointMethodMapping seiMethodMapping = null;
/* 176 */       if (seiMapping != null)
/*     */       {
/* 178 */         epMetaData.setServiceEndpointInterfaceName(seiMapping.getServiceEndpointInterface());
/*     */
/* 180 */         seiMethodMapping = seiMapping.getServiceEndpointMethodMappingByWsdlOperation(opName);
/* 181 */         if (seiMethodMapping == null) {
/* 182 */           throw new WSException("Cannot obtain method mapping for: " + opName);
/*     */         }
/* 184 */         javaName = seiMethodMapping.getJavaMethodName();
/*     */       }
/*     */
/* 187 */       OperationMetaData opMetaData = new OperationMetaData(epMetaData, opQName, javaName);
/* 188 */       epMetaData.addOperation(opMetaData);
/*     */
/* 191 */       String style = wsdlOperation.getStyle();
/* 192 */       epMetaData.setStyle("http://www.w3.org/2004/03/wsdl/style/iri".equals(style) ? Style.DOCUMENT : Style.RPC);
/*     */
/* 195 */       if ("http://www.w3.org/2004/08/wsdl/in-only".equals(wsdlOperation.getPattern())) {
/* 196 */         opMetaData.setOneWay(true);
/*     */       }
/*     */
/* 199 */       if (wsdlBindingOperation != null) {
/* 200 */         opMetaData.setSOAPAction(wsdlBindingOperation.getSOAPAction());
/*     */       }
/*     */
/* 203 */       String encStyle = epMetaData.getEncodingStyle().toURI();
/* 204 */       TypeMappingRegistry tmRegistry = new TypeMappingRegistryImpl();
/* 205 */       TypeMappingImpl typeMapping = (TypeMappingImpl)tmRegistry.getTypeMapping(encStyle);
View Full Code Here

/*     */
/*     */   private void buildParameterMetaDataRpc(OperationMetaData opMetaData, WSDLInterfaceOperation wsdlOperation, ServiceEndpointMethodMapping seiMethodMapping, TypeMappingImpl typeMapping)
/*     */   {
/* 551 */     this.log.trace("buildParameterMetaDataRpc: " + opMetaData.getQName());
/*     */
/* 553 */     WSDLBindingOperation bindingOperation = wsdlOperation.getBindingOperation();
/* 554 */     if (bindingOperation == null) {
/* 555 */       throw new WSException("Could not locate binding operation for:" + opMetaData.getQName());
/*     */     }
/*     */
/* 558 */     WSDLInterfaceOperationInput input = wsdlOperation.getInputs()[0];
View Full Code Here

/*     */
/*     */   private void buildParameterMetaDataDoc(OperationMetaData opMetaData, WSDLInterfaceOperation wsdlOperation, ServiceEndpointMethodMapping seiMethodMapping, TypeMappingImpl typeMapping)
/*     */   {
/* 873 */     this.log.trace("buildParameterMetaDataDoc: " + opMetaData.getQName());
/*     */
/* 875 */     WSDLBindingOperation bindingOperation = wsdlOperation.getBindingOperation();
/* 876 */     if (bindingOperation == null) {
/* 877 */       throw new WSException("Could not locate binding operation for:" + bindingOperation);
/*     */     }
/* 879 */     List wrappedParameters = new ArrayList();
/* 880 */     List wrappedResponseParameters = new ArrayList();
View Full Code Here

TOP

Related Classes of org.jboss.ws.metadata.wsdl.WSDLBindingOperation

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.