Question

So far I know how to write JavaDocs for functions and classes, but is there any way to write JavaDocs on a project-level? I was thinking mainly for information on who has contributed to the project, sources, references and such.

Was it helpful?

Solution

There is not much at project level. I see two options here:

Use the "package-level" which is possible (and advisable) in javadoc (possible since Java 1.5) . This use a specific java file named 'package-info.java' that you put along your other classes inside the package. Typical content is:

/**
 * com.destroyearth.raygun regroup all classes related to make the Raygun works.
 */
package com.destroyearth.raygun;

Use your dependency file (if you are using one), like Maven pom.xml. This is typically "projet level" and has some specific options for contributors (as it it much used in the Open Source world). Here is an exerpt, look at https://maven.apache.org/pom.html#More_Project_Information for more details:

  <developers>
    <developer>
      <id>eric</id>
      <name>Eric</name>
      <email>eredmond@codehaus.org</email>
      <url>http://eric.propellors.net</url>
      <organization>Codehaus</organization>
      <organizationUrl>http://mojo.codehaus.org</organizationUrl>
      <roles>
        <role>architect</role>
        <role>developer</role>
      </roles>
      <timezone>-6</timezone>
      <properties>
        <picUrl>http://tinyurl.com/prv4t</picUrl>
      </properties>
    </developer>
  </developers>

(if you are not using anything to manage your dependencies, start now).

OTHER TIPS

you could create a Class package-info.java in the top level package of your project. in This class is only the package declaration and a javaDoc comment. Link

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top