Win a copy of Five Lines of Code this week in the OO, Patterns, UML and Refactoring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

javadoc for generating api's

 
Ranch Hand
Posts: 209
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear Readers,
I have a package called maths which has two more packages namely;
server and client.

Basically its like this : maths.server and maths.client

Inside both the packages I have many files. I want to generate their details with the help of the javadoc tool.

I did this:
I navigated inside the server folder and typed the following command : javadoc -classpath ./ ServerListener.java

ServerListener is my main file inside the server package. But the other files are not linked when the HTML files are generated. Only deatils of the ServerListener class is generated. The following lines are generated alongwith an error:

Loading source file ServerListener.java...
Constructing Javadoc information...
ServerListener.java:14: cannot find symbol
symbol : class ClientThread
location: package maths.server
import maths.server.ClientThread;

^
Standard Doclet version 1.5.0
Building tree for all the packages and classes...
Generating maths/server/\ServerListener.html...
Generating maths/server/\package-frame.html...
Generating maths/server/\package-summary.html...
Generating maths/server/\package-tree.html...
Generating constant-values.html...
Building index for all the packages and classes...
Generating overview-tree.html...
Generating index-all.html...
Generating deprecated-list.html...
Building index for all classes...
Generating allclasses-frame.html...
Generating allclasses-noframe.html...
Generating index.html...
Generating help-doc.html...
Generating stylesheet.css...
1 warning
 
drifter
Posts: 1364
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check out the documentation on javadoc at javadoc - The Java API Documentation Generator.

Try running javadoc command from the top level, in the directory that your maths package is in. Did you want to just create the javadoc for that one class?

javadoc maths/server/ServerListener.java -d javadocDir

or to generate for maths and subpackages

javadoc -subpackages maths -d javadocDir



I add the -d so the javadoc files go to a separate directory.
[ May 14, 2005: Message edited by: Carol Enderlin ]
 
Shyam Prasad Murarka
Ranch Hand
Posts: 209
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear Carol,
Thank you very much. It worked.
 
Carol Enderlin
drifter
Posts: 1364
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

You're welcome!
 
If we don't do the shopping, we won't have anything for dinner. And I've invited this tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic