Menu

Exception on JDIFF 1.0.6

Help
2002-04-22
2002-04-23
  • Joseph Firebaugh

    I get the following error everytime I run JDIFF -- even the samples.  Any ideas why??  Thanks.

    JDiff: reading the old API in from file 'SuperProduct_1.0.xml'...javadoc: In doclet class jdiff.JDiff,  method start has thrown an exception java.lang.reflect.InvocationTargetException
    java.lang.IllegalArgumentException
            at sun.net.www.ParseUtil.decode(ParseUtil.java:94)
            at sun.misc.URLClassPath$FileLoader.<init>(URLClassPath.java:672)
            at sun.misc.URLClassPath$2.run(URLClassPath.java:254)
            at java.security.AccessController.doPrivileged(Native Method)
            at sun.misc.URLClassPath.getLoader(URLClassPath.java:248)
            at sun.misc.URLClassPath.getLoader(URLClassPath.java:225)
            at sun.misc.URLClassPath.getResource(URLClassPath.java:138)
            at java.net.URLClassLoader$ClassFinder.run(URLClassLoader.java:542)
            at java.security.AccessController.doPrivileged(Native Method)
            at java.net.URLClassLoader.findClass(URLClassLoader.java:203)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:325)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:257)
            at jdiff.JDiff.startGeneration(JDiff.java:66)
            at jdiff.JDiff.start(JDiff.java:29)
            at java.lang.reflect.Method.invoke(Native Method)
            at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:197)
            at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:99)

     
    • Matthew Doar

      Matthew Doar - 2002-04-23

      I'm not sure why the trace doesn't show it in more detail, (probably because it is invoked by reflection from the ANT Javadoc task), but what I believe is happening is that the appended code from XMLToApi.java is getting confused about where the Xerces parser is.

      Can you run it using the .bat or .csh files? (May give more precise errors)
      Try javap -classpath $CLASSPATH org.apache.xerces.parsers.SAXParser

      and check that the Xerces.jar file shipped with JDiff is being found in the classpath.

      You could also check that "org.xml.sax.driver" is not set in some variable being passed to java.

      ~Matt
      doar@pobox.com
                      String parserName = System.getProperty("org.xml.sax.driver");
                      if (parserName == null) {
                          parser = org.xml.sax.helpers.XMLReaderFactory.createXMLReader("org.apache.xerces.parsers.SAXParser");
                      } else {
                          // Let the underlying mechanisms try to work out which
                          // class to instantiate
                          parser = org.xml.sax.helpers.XMLReaderFactory.createXMLReader();
                      }

       

Log in to post a comment.