• Post Reply Bookmark Topic Watch Topic
  • New Topic

javadoc problem  RSS feed

 
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello, am trying out javadoc. I compiled the class MyClass below. But when I do "javadoc MyClass.java" it gives a java.lang.IllegalArgumentException. A html file is created but it's empty. What am I doing wrong?? Thank you


/** Description of MyClass
*
* @author John Doe
* @author Jane Doe
* @version 6.0z Build 9000 Jan 3, 1970.
*/
public class MyClass
{
/** Description of myIntField */
public int myIntField;
/** Description of MyClass()
*
* @throws MyException Description of myException
*/
public MyClass()
{
// Blah Blah Blah...
}

/** Description of myMethod(int a, String b)
*
* @param aDescription of a
* @param bDescription of b
* @returnDescription of c
*/
public Object myMethod(int a, String b)
{
Object c = null;
// Blah Blah Blah...
return c;
}
}
 
Marshal
Posts: 56610
172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Don't know. I tried it and it worked first time.
 
Ranch Hand
Posts: 188
Java jQuery Postgres Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This worked for me too, but the output did not reflect the following lines



are these lines not supposed to show?

I am using Netbeans 6.0.1.


(I thought I would follow on from this thread rather than starting a new one, not sure if this is good form)
 
Campbell Ritchie
Marshal
Posts: 56610
172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Marten Kay, it is probably not a good idea to reply to a 4-month old thread; if you have a new question a new thread might have been better.

You can find all sorts of details about the Javadoc tool on the Sun website; try starting here. Can't remember whether you are allowed the @author tag twice, but that might be part of the problem.
 
Sheriff
Posts: 21137
87
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For some fields, you have to specify explicitly that you want to include them. @author and @version are both among them.
 
marten kay
Ranch Hand
Posts: 188
Java jQuery Postgres Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Campbell, Rob

Thanks you both, and my apologies. I'll get it right one day.

Marten
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!