cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject svn commit: r544346 - in /incubator/cxf/trunk/tools/wsdlto: frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java
Date Tue, 05 Jun 2007 02:33:49 GMT
Author: ema
Date: Mon Jun  4 19:33:48 2007
New Revision: 544346

URL: http://svn.apache.org/viewvc?view=rev&rev=544346
Log:
Fixed issue CXF-627

Modified:
    incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java
    incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java

Modified: incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java?view=diff&rev=544346&r1=544345&r2=544346
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java
(original)
+++ incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java
Mon Jun  4 19:33:48 2007
@@ -242,13 +242,13 @@
 
     private boolean isAddedAsyMethod(JavaMethod method) {
         List<JavaMethod> jmethods = method.getInterface().getMethods();
+        int counter = 0;
         for (JavaMethod jm : jmethods) {
-            if (!jm.getName().toLowerCase().equals(method.getOperationName().toLowerCase())
-                && jm.getOperationName().toLowerCase().equals(method.getOperationName().toLowerCase()))
{
-                return  true;
-
+            if (jm.getOperationName().equals(method.getOperationName())) {
+                counter++;
             }
         }
-        return false;
+        return counter > 1 ? true : false;
     }
+    
 }

Modified: incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java?view=diff&rev=544346&r1=544345&r2=544346
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java
(original)
+++ incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java
Mon Jun  4 19:33:48 2007
@@ -520,6 +520,21 @@
     }
     
     
+    @Test
+    public void testCXF627() throws Exception {
+
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/bug627/hello_world.wsdl"));
+        env.put(ToolConstants.CFG_BINDING, getLocation("/wsdl2java_wsdl/bug627/async_binding.xml"));
+        processor.setContext(env);
+        processor.execute();
+        
+        
+        Class clz = classLoader.loadClass("org.apache.hello_world_soap_http.Greeter");
+        assertEquals(3, clz.getDeclaredMethods().length); 
+
+    }
+    
+    
     
 
 }



Mime
View raw message