ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ste...@apache.org
Subject cvs commit: jakarta-ant/src/main/org/apache/tools/ant/util JavaEnvUtils.java
Date Fri, 28 Jun 2002 06:10:48 GMT
stevel      2002/06/27 23:10:48

  Modified:    src/main/org/apache/tools/ant/util Tag: ANT_15_BRANCH
                        JavaEnvUtils.java
  Log:
  putting the test data for this fix so that people remember to update it when they change
the code.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.2.4   +60 -3     jakarta-ant/src/main/org/apache/tools/ant/util/JavaEnvUtils.java
  
  Index: JavaEnvUtils.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/util/JavaEnvUtils.java,v
  retrieving revision 1.3.2.3
  retrieving revision 1.3.2.4
  diff -u -r1.3.2.3 -r1.3.2.4
  --- JavaEnvUtils.java	17 Jun 2002 04:43:40 -0000	1.3.2.3
  +++ JavaEnvUtils.java	28 Jun 2002 06:10:47 -0000	1.3.2.4
  @@ -56,6 +56,7 @@
   import org.apache.tools.ant.taskdefs.condition.Os;
   import java.io.File;
   import java.util.Vector;
  +import java.util.List;
   
   /**
    * A set of helper methods related to locating executables or checking
  @@ -268,7 +269,8 @@
       }
           
       /**
  -     * demand creation of the package list
  +     * demand creation of the package list.
  +     * When you add a new package, add a new test below
        */
        
       private static void buildJrePackages() {
  @@ -279,24 +281,79 @@
                   jrePackages.addElement("org.apache.xalan");
                   jrePackages.addElement("org.apache.xml");
                   jrePackages.addElement("org.apache.xpath");
  +                jrePackages.addElement("org.ietf.jgss");
                   jrePackages.addElement("org.w3c.dom");
                   jrePackages.addElement("org.xml.sax");
                   // fall through
               case 13:    
                   jrePackages.addElement("org.omg");
  +                jrePackages.addElement("com.sun.corba");
  +                jrePackages.addElement("com.sun.jndi");
  +                jrePackages.addElement("com.sun.media");
  +                jrePackages.addElement("com.sun.naming");
  +                jrePackages.addElement("com.sun.org.omg");
  +                jrePackages.addElement("com.sun.rmi");
  +                jrePackages.addElement("sunw.io");
  +                jrePackages.addElement("sunw.util");
                   // fall through
               case 12:    
  -                jrePackages.addElement("sun.misc");
  +                jrePackages.addElement("com.sun.java");
  +                jrePackages.addElement("com.sun.image");
                   // are there any here that we forgot?
                   // fall through
               case 11:    
               default:
  +                //things like sun.reflection, sun.misc, sun.net
  +                jrePackages.addElement("sun.");
                   jrePackages.addElement("java");
                   jrePackages.addElement("javax");
                   break;
           }
       }
  -    
  +
  +    /**
  +     * testing helper method; kept here for unification of changes.
  +     * @return
  +     */
  +    public static Vector getJrePackageTestCases() {
  +        Vector tests=new Vector();
  +        tests.addElement("java.lang.Object");
  +        switch(javaVersionNumber) {
  +            case 14:
  +                tests.addElement("sun.audio.AudioPlayer");
  +                tests.addElement("org.apache.crimson.parser.ContentModel");
  +                tests.addElement("org.apache.xalan.processor.ProcessorImport");
  +                tests.addElement("org.apache.xml.utils.URI");
  +                tests.addElement("org.apache.xpath.XPathFactory");
  +                tests.addElement("org.ietf.jgss.Oid");
  +                tests.addElement("org.w3c.dom.Attr");
  +                tests.addElement("org.xml.sax.XMLReader");
  +                // fall through
  +            case 13:
  +                tests.addElement("org.omg.CORBA.Any");
  +                tests.addElement("com.sun.corba.se.internal.corba.AnyImpl");
  +                tests.addElement("com.sun.jndi.ldap.LdapURL");
  +                tests.addElement("com.sun.media.sound.Printer");
  +                tests.addElement("com.sun.naming.internal.VersionHelper");
  +                tests.addElement("com.sun.org.omg.CORBA.Initializer");
  +                tests.addElement("sunw.io.Serializable");
  +                tests.addElement("sunw.util.EventListener");
  +                // fall through
  +            case 12:
  +                tests.addElement("javax.accessibility.Accessible");
  +                tests.addElement("sun.misc.BASE64Encoder");
  +                tests.addElement("com.sun.image.codec.jpeg.JPEGCodec");
  +                // fall through
  +            case 11:
  +            default:
  +                //things like sun.reflection, sun.misc, sun.net
  +                tests.addElement("sun.reflect.SerializationConstructorAccessorImpl");
  +                tests.addElement("sun.net.www.http.HttpClient");
  +                tests.addElement("sun.audio.AudioPlayer");
  +                break;
  +        }
  +        return tests;
  +    }
       /**
        * get a vector of strings of packages built into 
        * that platforms runtime jar(s)
  
  
  

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message