cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pruss...@locus.apache.org
Subject cvs commit: xml-cocoon/src/org/apache/cocoon/components/language/programming/java Javac.java
Date Mon, 18 Dec 2000 21:17:30 GMT
prussell    00/12/18 13:17:29

  Modified:    src/org/apache/cocoon/util Tag: xml-cocoon2 ClassUtils.java
               src/org/apache/cocoon/components/language/programming/java
                        Tag: xml-cocoon2 Javac.java
  Log:
  Cleaned up exceptions thrown by classutils, and improved Javac logging.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.7   +3 -3      xml-cocoon/src/org/apache/cocoon/util/Attic/ClassUtils.java
  
  Index: ClassUtils.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon/src/org/apache/cocoon/util/Attic/ClassUtils.java,v
  retrieving revision 1.1.2.6
  retrieving revision 1.1.2.7
  diff -u -r1.1.2.6 -r1.1.2.7
  --- ClassUtils.java	2000/12/18 15:01:20	1.1.2.6
  +++ ClassUtils.java	2000/12/18 21:17:28	1.1.2.7
  @@ -21,7 +21,7 @@
    *
    * @author <a href="mailto:ricardo@apache.org">Ricardo Rocha</a>
    * @author <a href="mailto:stefano@apache.org">Stefano Mazzocchi</a>
  - * @version CVS $Revision: 1.1.2.6 $ $Date: 2000/12/18 15:01:20 $
  + * @version CVS $Revision: 1.1.2.7 $ $Date: 2000/12/18 21:17:28 $
    */
   public class ClassUtils {
   
  @@ -48,9 +48,9 @@
        *
        * @param className A class name
        * @return The class pointed to by <code>className</code>
  -     * @exception Exception If a loading error occurs
  +     * @exception ClassNotFoundException If a loading error occurs
        */
  -    public static Class loadClass(String className) throws Exception {
  +    public static Class loadClass(String className) throws ClassNotFoundException {
           return Class.forName(className);
       }
   
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.9   +4 -4      xml-cocoon/src/org/apache/cocoon/components/language/programming/java/Attic/Javac.java
  
  Index: Javac.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon/src/org/apache/cocoon/components/language/programming/java/Attic/Javac.java,v
  retrieving revision 1.1.2.8
  retrieving revision 1.1.2.9
  diff -u -r1.1.2.8 -r1.1.2.9
  --- Javac.java	2000/12/18 15:01:09	1.1.2.8
  +++ Javac.java	2000/12/18 21:17:29	1.1.2.9
  @@ -17,7 +17,7 @@
    * This class wraps the Sun's Javac Compiler.
    *
    * @author <a href="mailto:stefano@apache.org">Stefano Mazzocchi</a>
  - * @version $Revision: 1.1.2.8 $ $Date: 2000/12/18 15:01:09 $
  + * @version $Revision: 1.1.2.9 $ $Date: 2000/12/18 21:17:29 $
    * @since 2.0
    */
   
  @@ -34,13 +34,13 @@
       try {
           ClassUtils.loadClass(MODERN_CLASS);
           modern = true;
  -    } catch (Exception e) {
  -        log.warn("Javac()", e);
  +    } catch (ClassNotFoundException e) {
  +        log.warn("Javac connector could not find modern compiler -- falling back to classic.");
           try {
               ClassUtils.loadClass(CLASSIC_CLASS);
               modern = false;
           } catch (Exception ex) {
  -            log.warn("No compiler found in your classpath. Make sure you added 'tools.jar'",
ex);
  +            log.error("No compiler found in your classpath. Make sure you added 'tools.jar'",
ex);
               throw new RuntimeException("No compiler found in your classpath. Make sure
you added 'tools.jar'");
           }
       }
  
  
  

Mime
View raw message