2 Replies Latest reply: Sep 4, 2008 3:03 AM by thomas.behr RSS

    javadoc command

    843810
      Hi,

      I know this is a bit idiotic question to ask in this forum but i a m helpless.

      I ahve a java file Test.java under the hierarchy "D:/src/com/open/Test.java". This java file contains proper tags. Now i want to generate the javadoc foe this Test.java file. i am using eclipse. I tried generating javadocs by using eclipse but got this error. (Don't know what it's all about)

      java.lang.IllegalArgumentException
           at sun.net.www.ParseUtil.decode(ParseUtil.java:183)
           at sun.misc.URLClassPath$FileLoader.<init>(URLClassPath.java:863)
           at sun.misc.URLClassPath$3.run(URLClassPath.java:319)
           at java.security.AccessController.doPrivileged(Native Method)
           at sun.misc.URLClassPath.getLoader(URLClassPath.java:313)
           at sun.misc.URLClassPath.getLoader(URLClassPath.java:290)
           at sun.misc.URLClassPath.findResource(URLClassPath.java:141)
           at java.net.URLClassLoader$2.run(URLClassLoader.java:362)
           at java.security.AccessController.doPrivileged(Native Method)
           at java.net.URLClassLoader.findResource(URLClassLoader.java:359)
           at java.lang.ClassLoader.getResource(ClassLoader.java:977)
           at java.lang.ClassLoader.getResourceAsStream(ClassLoader.java:1159)
           at javax.xml.parsers.SecuritySupport$4.run(SecuritySupport.java:72)
           at java.security.AccessController.doPrivileged(Native Method)
           at javax.xml.parsers.SecuritySupport.getResourceAsStream(SecuritySupport.java:65)
           at javax.xml.parsers.FactoryFinder.findJarServiceProvider(FactoryFinder.java:213)
           at javax.xml.parsers.FactoryFinder.find(FactoryFinder.java:185)
           at javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:107)
           at com.sun.tools.doclets.internal.toolkit.builders.LayoutParser.parseXML(LayoutParser.java:72)
           at com.sun.tools.doclets.internal.toolkit.builders.ClassBuilder.build(ClassBuilder.java:108)
           at com.sun.tools.doclets.formats.html.HtmlDoclet.generateClassFiles(HtmlDoclet.java:155)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:177)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:161)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.startGeneration(AbstractDoclet.java:106)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.start(AbstractDoclet.java:64)
           at com.sun.tools.doclets.formats.html.HtmlDoclet.start(HtmlDoclet.java:42)
           at com.sun.tools.doclets.standard.Standard.start(Standard.java:23)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
           at java.lang.reflect.Method.invoke(Method.java:585)
           at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:269)
           at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:143)
           at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:340)
           at com.sun.tools.javadoc.Start.begin(Start.java:128)
           at com.sun.tools.javadoc.Main.execute(Main.java:41)
           at com.sun.tools.javadoc.Main.main(Main.java:31)
      com.sun.tools.doclets.internal.toolkit.util.DocletAbortException
           at com.sun.tools.doclets.internal.toolkit.builders.LayoutParser.parseXML(LayoutParser.java:79)
           at com.sun.tools.doclets.internal.toolkit.builders.ClassBuilder.build(ClassBuilder.java:108)
           at com.sun.tools.doclets.formats.html.HtmlDoclet.generateClassFiles(HtmlDoclet.java:155)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:177)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:161)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.startGeneration(AbstractDoclet.java:106)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.start(AbstractDoclet.java:64)
           at com.sun.tools.doclets.formats.html.HtmlDoclet.start(HtmlDoclet.java:42)
           at com.sun.tools.doclets.standard.Standard.start(Standard.java:23)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
           at java.lang.reflect.Method.invoke(Method.java:585)
           at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:269)
           at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:143)
           at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:340)
           at com.sun.tools.javadoc.Start.begin(Start.java:128)
           at com.sun.tools.javadoc.Main.execute(Main.java:41)
           at com.sun.tools.javadoc.Main.main(Main.java:31)
      com.sun.tools.doclets.internal.toolkit.util.DocletAbortException
           at com.sun.tools.doclets.formats.html.HtmlDoclet.generateClassFiles(HtmlDoclet.java:159)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:177)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:161)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.startGeneration(AbstractDoclet.java:106)
           at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.start(AbstractDoclet.java:64)
           at com.sun.tools.doclets.formats.html.HtmlDoclet.start(HtmlDoclet.java:42)
           at com.sun.tools.doclets.standard.Standard.start(Standard.java:23)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
           at java.lang.reflect.Method.invoke(Method.java:585)
           at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:269)
           at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:143)
           at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:340)
           at com.sun.tools.javadoc.Start.begin(Start.java:128)
           at com.sun.tools.javadoc.Main.execute(Main.java:41)
           at com.sun.tools.javadoc.Main.main(Main.java:31)


      Could anybobody please let me know the command to generate the javadoc.

      Thanks in advance
      Piyush
        • 1. Re: javadoc command
          843810
          I am also facing the same problem. I know it may be a silly mistake somewhere but If somebody can point out the issue I will be thankful.

          I am using eclipse europa (version 3.3.0) and trying to generate javadocs for a simple java project containing a single java file.

          I use javadoc.exe present in jdk1.5.0_12\bin\.

          The same program works on my colleagues PC using the same version of eclipse & he is able to generate the javadocs. Need your help in this regard. Not sure if I am mailing to the correct email id.



          But it gives me an error as below :-



          Loading source file D:\Vipin\Technical\javadoctest\src\a.java...

          Loading source file D:\Vipin\Technical\javadoctest\src\samplejavadoc.java...

          Constructing Javadoc information...

          Standard Doclet version 1.5.0_12

          Building tree for all the packages and classes...

          Generating D:\Vipin\Technical\javadoctest\doc\a.html...

          java.lang.IllegalArgumentException

          at sun.net.www.ParseUtil.decode(ParseUtil.java:185)

          at sun.misc.URLClassPath$FileLoader.<init>(URLClassPath.java:863)

          at sun.misc.URLClassPath$3.run(URLClassPath.java:319)

          at java.security.AccessController.doPrivileged(Native Method)

          at sun.misc.URLClassPath.getLoader(URLClassPath.java:313)

          at sun.misc.URLClassPath.getLoader(URLClassPath.java:290)

          at sun.misc.URLClassPath.findResource(URLClassPath.java:141)

          at java.net.URLClassLoader$2.run(URLClassLoader.java:362)

          at java.security.AccessController.doPrivileged(Native Method)

          at java.net.URLClassLoader.findResource(URLClassLoader.java:359)

          at java.lang.ClassLoader.getResource(ClassLoader.java:977)

          at java.lang.ClassLoader.getResourceAsStream(ClassLoader.java:1159)

          at javax.xml.parsers.SecuritySupport$4.run(SecuritySupport.java:72)

          at java.security.AccessController.doPrivileged(Native Method)

          at javax.xml.parsers.SecuritySupport.getResourceAsStream(SecuritySupport.java:65)

          at javax.xml.parsers.FactoryFinder.findJarServiceProvider(FactoryFinder.java:213)

          at javax.xml.parsers.FactoryFinder.find(FactoryFinder.java:185)

          at javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:107)

          at com.sun.tools.doclets.internal.toolkit.builders.LayoutParser.parseXML(LayoutParser.java:72)

          at com.sun.tools.doclets.internal.toolkit.builders.ClassBuilder.build(ClassBuilder.java:108)

          at com.sun.tools.doclets.formats.html.HtmlDoclet.generateClassFiles(HtmlDoclet.java:155)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:177)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:161)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.startGeneration(AbstractDoclet.java:106)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.start(AbstractDoclet.java:64)

          at com.sun.tools.doclets.formats.html.HtmlDoclet.start(HtmlDoclet.java:42)

          at com.sun.tools.doclets.standard.Standard.start(Standard.java:23)

          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

          at java.lang.reflect.Method.invoke(Method.java:585)

          at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:269)

          at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:143)

          at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:340)

          at com.sun.tools.javadoc.Start.begin(Start.java:128)

          at com.sun.tools.javadoc.Main.execute(Main.java:41)

          at com.sun.tools.javadoc.Main.main(Main.java:31)

          com.sun.tools.doclets.internal.toolkit.util.DocletAbortException

          at com.sun.tools.doclets.internal.toolkit.builders.LayoutParser.parseXML(LayoutParser.java:79)

          at com.sun.tools.doclets.internal.toolkit.builders.ClassBuilder.build(ClassBuilder.java:108)

          at com.sun.tools.doclets.formats.html.HtmlDoclet.generateClassFiles(HtmlDoclet.java:155)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:177)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:161)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.startGeneration(AbstractDoclet.java:106)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.start(AbstractDoclet.java:64)

          at com.sun.tools.doclets.formats.html.HtmlDoclet.start(HtmlDoclet.java:42)

          at com.sun.tools.doclets.standard.Standard.start(Standard.java:23)

          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

          at java.lang.reflect.Method.invoke(Method.java:585)

          at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:269)

          at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:143)

          at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:340)

          at com.sun.tools.javadoc.Start.begin(Start.java:128)

          at com.sun.tools.javadoc.Main.execute(Main.java:41)

          at com.sun.tools.javadoc.Main.main(Main.java:31)

          com.sun.tools.doclets.internal.toolkit.util.DocletAbortException

          at com.sun.tools.doclets.formats.html.HtmlDoclet.generateClassFiles(HtmlDoclet.java:159)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:177)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:161)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.startGeneration(AbstractDoclet.java:106)

          at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.start(AbstractDoclet.java:64)

          at com.sun.tools.doclets.formats.html.HtmlDoclet.start(HtmlDoclet.java:42)

          at com.sun.tools.doclets.standard.Standard.start(Standard.java:23)

          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

          at java.lang.reflect.Method.invoke(Method.java:585)

          at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:269)

          at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:143)

          at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:340)

          at com.sun.tools.javadoc.Start.begin(Start.java:128)

          at com.sun.tools.javadoc.Main.execute(Main.java:41)

          at com.sun.tools.javadoc.Main.main(Main.java:31)





          Thanks

          Vipin
          • 2. Re: javadoc command
            thomas.behr
            I suggest you check whether this is really a Javadoc problem or rather an eclipse issue, i.e. try to generate the API documentation from outside eclipse by running javadoc from the commandline. If the problem still occurs, post your sources.