cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject svn commit: r542495 - in /incubator/cxf/trunk/tools: javato/src/main/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/ wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/ wsdlto/test/src/test/j...
Date Tue, 29 May 2007 11:51:20 GMT
Author: ema
Date: Tue May 29 04:51:19 2007
New Revision: 542495

URL: http://svn.apache.org/viewvc?view=rev&rev=542495
Log:
Fixed @WebResult and @WebParam in wrong targetNamespace for wrapped method   

Modified:
    incubator/cxf/trunk/tools/javato/src/main/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/ResponseWrapper.java
    incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/ParameterProcessor.java
    incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java
    incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java

Modified: incubator/cxf/trunk/tools/javato/src/main/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/ResponseWrapper.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/javato/src/main/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/ResponseWrapper.java?view=diff&rev=542495&r1=542494&r2=542495
==============================================================================
--- incubator/cxf/trunk/tools/javato/src/main/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/ResponseWrapper.java
(original)
+++ incubator/cxf/trunk/tools/javato/src/main/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/ResponseWrapper.java
Tue May 29 04:51:19 2007
@@ -76,7 +76,7 @@
                 type = returnType.getName();
             }
             field.setType(type);
-            field.setTargetNamespace("");
+            //field.setTargetNamespace("");
         }
         fields.add(field);
         

Modified: incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/ParameterProcessor.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/ParameterProcessor.java?view=diff&rev=542495&r1=542494&r2=542495
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/ParameterProcessor.java
(original)
+++ incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/ParameterProcessor.java
Tue May 29 04:51:19 2007
@@ -293,13 +293,8 @@
         String fullJavaName = "";
               
         fullJavaName = this.dataBinding.getWrappedElementType(wrapperElement, item);
-        
-        String targetNamespace = "";
-        Object obj = part.getProperty("messagepart.isheader");
-        if (Boolean.TRUE.equals(obj)) {
-            targetNamespace = part.getMessageInfo().getOperation().getInterface().
-            getService().getTargetNamespace();
-        } 
+
+        String targetNamespace = item.getNamespaceURI();    
         
         String jpname = ProcessorUtil.mangleNameToVariableName(item.getLocalPart());
         JavaParameter parameter = new JavaParameter(jpname, fullJavaName, targetNamespace);
@@ -337,7 +332,9 @@
         if (Boolean.TRUE.equals(obj)) {
             targetNamespace = part.getMessageInfo().getOperation().getInterface().
             getService().getTargetNamespace();
-        } 
+        }  else {
+            targetNamespace = element.getNamespaceURI();
+        }
         
         String jpname = ProcessorUtil.mangleNameToVariableName(simpleJavaName);
         JavaReturn returnType = new JavaReturn(jpname, fullJavaName , targetNamespace);

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=542495&r1=542494&r2=542495
==============================================================================
--- 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
Tue May 29 04:51:19 2007
@@ -495,7 +495,7 @@
     public void testCXF677() throws Exception {
         
        
-        String[] args = new String[] {"-d", output.getCanonicalPath(), "-verbose", 
+        String[] args = new String[] {"-d", output.getCanonicalPath(), 
                                       "-b", 
                                       getLocation("/wsdl2java_wsdl/hello-mime-binding.xml"),
                                       getLocation("/wsdl2java_wsdl/hello-mime.wsdl")};

Modified: incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java?view=diff&rev=542495&r1=542494&r2=542495
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
(original)
+++ incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
Tue May 29 04:51:19 2007
@@ -282,8 +282,8 @@
         assertEquals("String", method.getReturnType().getSimpleName());
         WebParam webParamAnn = AnnotationUtil.getWebParam(method, "requestType");
         //if is wrapped, tns should be empty
-        //assertEquals("http://apache.org/hello_world_soap_http/types", webParamAnn.targetNamespace());
-        assertEquals("", webParamAnn.targetNamespace());
+        assertEquals("http://apache.org/hello_world_soap_http/types", webParamAnn.targetNamespace());
+        //assertEquals("", webParamAnn.targetNamespace());
         method = clz.getMethod("greetMeOneWay", new Class[] {String.class});
         Oneway oneWayAnn = AnnotationUtil.getPrivMethodAnnotation(method, Oneway.class);
         assertNotNull("OneWay Annotation is not generated", oneWayAnn);



Mime
View raw message