axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: xml-axis/java/src/org/apache/axis/wsdl/toJava Utils.java
Date Fri, 14 Mar 2003 16:14:38 GMT
dims        2003/03/14 08:14:37

  Modified:    java/test/utils TestJavaUtils.java
               java/src/org/apache/axis/wsdl/toJava Utils.java
  Log:
  Fix for Bug 17995 - wsdl2java converts namespace to uncompilable packages
  
  Notes:
  - Use ':' as a delimiter for host...Since in IPv6 localhost is 0:0:0:0:0:0:0:1
  
  Revision  Changes    Path
  1.20      +8 -0      xml-axis/java/test/utils/TestJavaUtils.java
  
  Index: TestJavaUtils.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/test/utils/TestJavaUtils.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- TestJavaUtils.java	14 Mar 2003 15:36:06 -0000	1.19
  +++ TestJavaUtils.java	14 Mar 2003 16:14:37 -0000	1.20
  @@ -4,6 +4,7 @@
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.apache.axis.utils.JavaUtils;
  +import org.apache.axis.wsdl.toJava.Utils;
   
   import javax.xml.rpc.holders.ByteHolder;
   import javax.xml.rpc.holders.LongHolder;
  @@ -105,6 +106,13 @@
        */ 
       public void testXmlNameToJava2() {
           assertEquals("_abstract", JavaUtils.xmlNameToJava("abstract"));
  +    }
  +    
  +    /**
  +     * Test for Bug 17995 - wsdl2java converts namespace to uncompilable packages
  +     */ 
  +    public void testPackageNaming() {
  +        assertEquals("_0._1.util.liberty", Utils.makePackageName("urn:liberty:util:1.0"));
       }
       
       /**
  
  
  
  1.74      +1 -1      xml-axis/java/src/org/apache/axis/wsdl/toJava/Utils.java
  
  Index: Utils.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/wsdl/toJava/Utils.java,v
  retrieving revision 1.73
  retrieving revision 1.74
  diff -u -r1.73 -r1.74
  --- Utils.java	12 Mar 2003 21:41:17 -0000	1.73
  +++ Utils.java	14 Mar 2003 16:14:37 -0000	1.74
  @@ -444,7 +444,7 @@
           }
   
           // tokenize the hostname and reverse it
  -        StringTokenizer st = new StringTokenizer( hostname, "." );
  +        StringTokenizer st = new StringTokenizer( hostname, ".:" );
           String[] words = new String[ st.countTokens() ];
           for(int i = 0; i < words.length; ++i)
               words[i] = st.nextToken();
  
  
  

Mime
View raw message