axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chath...@apache.org
Subject svn commit: r354259 - /webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/XMLBeansExtension.java
Date Tue, 06 Dec 2005 02:03:17 GMT
Author: chathura
Date: Mon Dec  5 18:01:20 2005
New Revision: 354259

URL: http://svn.apache.org/viewcvs?rev=354259&view=rev
Log:
The resolution for issue AXIS2-323

Modified:
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/XMLBeansExtension.java

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/XMLBeansExtension.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/XMLBeansExtension.java?rev=354259&r1=354258&r2=354259&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/XMLBeansExtension.java
(original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/XMLBeansExtension.java
Mon Dec  5 18:01:20 2005
@@ -23,6 +23,7 @@
 import org.apache.axis2.wsdl.databinding.JavaTypeMapper;
 import org.apache.axis2.wsdl.util.ConfigPropertyFileLoader;
 import org.apache.wsdl.WSDLBinding;
+import org.apache.wsdl.WSDLBindingMessageReference;
 import org.apache.wsdl.WSDLBindingOperation;
 import org.apache.wsdl.WSDLConstants;
 import org.apache.wsdl.WSDLExtensibilityElement;
@@ -323,18 +324,21 @@
     }
 
     protected void foo(WSDLBindingOperation bindingOp) {
-        Iterator extIterator = bindingOp.getInput().getExtensibilityElements()
-                .iterator();
-        while (extIterator.hasNext()) {
-            WSDLExtensibilityElement element = (WSDLExtensibilityElement) extIterator.next();
-            if (ExtensionConstants.SOAP_11_BODY.equals(element.getType()) ||
-                    ExtensionConstants.SOAP_12_BODY.equals(element.getType())) {
-                if (WSDLConstants.WSDL_USE_ENCODED.equals(
-                        ((SOAPBody) element).getUse())) {
-                    throw new RuntimeException(
-                            "The use 'encoded' is not supported!");
-                }
-            }
+        WSDLBindingMessageReference input = bindingOp.getInput();
+        if(input != null){
+			Iterator extIterator = input.getExtensibilityElements()
+	                .iterator();
+	        while (extIterator.hasNext()) {
+	            WSDLExtensibilityElement element = (WSDLExtensibilityElement) extIterator.next();
+	            if (ExtensionConstants.SOAP_11_BODY.equals(element.getType()) ||
+	                    ExtensionConstants.SOAP_12_BODY.equals(element.getType())) {
+	                if (WSDLConstants.WSDL_USE_ENCODED.equals(
+	                        ((SOAPBody) element).getUse())) {
+	                    throw new RuntimeException(
+	                            "The use 'encoded' is not supported!");
+	                }
+	            }
+	        }
         }
     }
 



Mime
View raw message