cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1294951 - in /cxf/branches/2.4.x-fixes: ./ api/src/main/java/org/apache/cxf/tools/common/ tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/customization/ tools/wsdlto/test/src/test/java/org/apache/cxf/to...
Date Wed, 29 Feb 2012 02:47:46 GMT
Author: dkulp
Date: Wed Feb 29 02:47:46 2012
New Revision: 1294951

URL: http://svn.apache.org/viewvc?rev=1294951&view=rev
Log:
Merged revisions 1293072 via  svn merge from
https://svn.apache.org/repos/asf/cxf/branches/2.5.x-fixes

........
  r1293072 | ema | 2012-02-23 23:06:49 -0500 (Thu, 23 Feb 2012) | 9 lines
  
  Merged revisions 1293064 via svnmerge from 
  https://svn.apache.org/repos/asf/cxf/trunk
  
  ........
    r1293064 | ema | 2012-02-24 11:05:55 +0800 (Fri, 24 Feb 2012) | 1 line
    
    [CXF-4135]:Allow xsd shema file as a jaxb binding file to pass into JAXB schmeCompiler
  ........
  
........

Modified:
    cxf/branches/2.4.x-fixes/   (props changed)
    cxf/branches/2.4.x-fixes/api/src/main/java/org/apache/cxf/tools/common/ToolConstants.java
    cxf/branches/2.4.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/customization/CustomizationParser.java
    cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java

Propchange: cxf/branches/2.4.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.4.x-fixes/api/src/main/java/org/apache/cxf/tools/common/ToolConstants.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/api/src/main/java/org/apache/cxf/tools/common/ToolConstants.java?rev=1294951&r1=1294950&r2=1294951&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/api/src/main/java/org/apache/cxf/tools/common/ToolConstants.java
(original)
+++ cxf/branches/2.4.x-fixes/api/src/main/java/org/apache/cxf/tools/common/ToolConstants.java
Wed Feb 29 02:47:46 2012
@@ -167,6 +167,7 @@ public final class ToolConstants {
     public static final String NS_JAXB_BINDINGS = "http://java.sun.com/xml/ns/jaxb";
     public static final QName  JAXWS_BINDINGS = new QName(NS_JAXWS_BINDINGS, "bindings");
     public static final QName  JAXB_BINDINGS = new QName(NS_JAXB_BINDINGS, "bindings");
+    public static final QName SCHEMA = new QName(SCHEMA_URI, "schema");
     public static final String JAXWS_BINDINGS_WSDL_LOCATION = "wsdlLocation";
     public static final String JAXWS_BINDING_NODE = "node";
     public static final String JAXWS_BINDING_VERSION = "version";

Modified: cxf/branches/2.4.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/customization/CustomizationParser.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/customization/CustomizationParser.java?rev=1294951&r1=1294950&r2=1294951&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/customization/CustomizationParser.java
(original)
+++ cxf/branches/2.4.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/customization/CustomizationParser.java
Wed Feb 29 02:47:46 2012
@@ -572,8 +572,8 @@ public final class CustomizationParser {
     }
 
     private boolean isValidJaxbBindingFile(XMLStreamReader reader) {
-        if (ToolConstants.JAXB_BINDINGS.equals(reader.getName())) {
-
+        if (ToolConstants.JAXB_BINDINGS.equals(reader.getName())
+            || ToolConstants.SCHEMA.equals(reader.getName())) {
             return true;
         }
         return false;

Modified: cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java?rev=1294951&r1=1294950&r2=1294951&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
(original)
+++ cxf/branches/2.4.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
Wed Feb 29 02:47:46 2012
@@ -1625,4 +1625,18 @@ public class CodeGenTest extends Abstrac
 
     }
 
+    
+    @Test
+    // CXF-4135
+    public void testPassShemaFileAsJAXBBinding() throws Exception {
+        env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/hello_world.wsdl"));
+        env.put(ToolConstants.CFG_BINDING, getLocation("/wsdl2java_wsdl/Invoice.xsd"));
+        processor.setContext(env);
+        processor.execute();
+        File generateFromBindingFile = new File(output, "org/apache/invoice/Invoice.java");
+        assertTrue(generateFromBindingFile.exists());
+        File seiFile = new File(output, "org/apache/cxf/w2j/hello_world_soap_http/Greeter.java");
+        assertTrue(seiFile.exists());
+    }
+    
 }



Mime
View raw message