cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1328322 - /cxf/trunk/tools/wadlto/jaxrs/src/main/java/org/apache/cxf/tools/wadlto/jaxrs/SourceGenerator.java
Date Fri, 20 Apr 2012 11:11:13 GMT
Author: sergeyb
Date: Fri Apr 20 11:11:13 2012
New Revision: 1328322

URL: http://svn.apache.org/viewvc?rev=1328322&view=rev
Log:
Minor update to WADL generator to get enum classes generated properly

Modified:
    cxf/trunk/tools/wadlto/jaxrs/src/main/java/org/apache/cxf/tools/wadlto/jaxrs/SourceGenerator.java

Modified: cxf/trunk/tools/wadlto/jaxrs/src/main/java/org/apache/cxf/tools/wadlto/jaxrs/SourceGenerator.java
URL: http://svn.apache.org/viewvc/cxf/trunk/tools/wadlto/jaxrs/src/main/java/org/apache/cxf/tools/wadlto/jaxrs/SourceGenerator.java?rev=1328322&r1=1328321&r2=1328322&view=diff
==============================================================================
--- cxf/trunk/tools/wadlto/jaxrs/src/main/java/org/apache/cxf/tools/wadlto/jaxrs/SourceGenerator.java
(original)
+++ cxf/trunk/tools/wadlto/jaxrs/src/main/java/org/apache/cxf/tools/wadlto/jaxrs/SourceGenerator.java
Fri Apr 20 11:11:13 2012
@@ -924,7 +924,8 @@ public class SourceGenerator {
         if (theName.length() == 1) {
             return theName;
         } else {
-            return theName.substring(0, 1) + theName.substring(1).toLowerCase();
+            theName = theName.substring(0, 1) + theName.substring(1).toLowerCase();
+            return theName.replaceAll("[\\.\\-]", "_");
         }
     }
     



Mime
View raw message