Using Alternate Doclet

To generate output from an alternate doclet, add configuration similar to the following to your POM.

In this example, the doclet is UmlGraph (http://www.umlgraph.org/). UmlGraph allows the declarative specification and drawing of UML class and sequence diagrams.

Note about UmlGraph: You must have the Graphviz binary in your PATH, or the images will not be generated. For more information about Graphviz, please refer to http://www.graphviz.org/.

<project>
  ...
  <reporting> (or <build>)
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>2.9.1</version>
        <configuration>
          <doclet>org.umlgraph.doclet.UmlGraphDoc</doclet>

          <!-- <docletPath>/path/to/UmlGraph.jar</docletPath> -->
          <docletArtifact>
            <groupId>org.umlgraph</groupId>
            <artifactId>doclet</artifactId>
            <version>5.1</version>
          </docletArtifact>
          <additionalparam>-views</additionalparam>
          <useStandardDocletOptions>true</useStandardDocletOptions>
        </configuration>
      </plugin>
    ...
    </plugins>
  </reporting> (or </build>)
  ...
</project>

Note:

After executing mvn site, you will see that a UML graph (.dot file) will be generated in the destination directory.

Using Alternate Doclet In Addition To The Javadoc Doclet

To generate output from an alternate doclet in addition to the normal HTML Javadoc doclet, add configuration similar to the following to your POM.

In this example, the doclet is Sun DocCheck (http://docs.oracle.com/javase/7/docs/technotes/guides/javadoc/doccheck/). The Sun Doc Check Doclet is an extension to the Javadoc tool. It runs on source code and reviews documentation comments, generating an HTML report that identifies empty comments and other ommissions and irregularities in the documentation comments.

<project>
  ...
  <reporting>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>2.9.1</version>
        <reportSets>
          <reportSet>
            <id>html</id>
            <reports>
              <report>javadoc</report>
            </reports>
          </reportSet>
          <reportSet>
            <id>doccheck</id>
            <configuration>
              <doclet>com.sun.tools.doclets.doccheck.DocCheck</doclet>

              <!-- <docletPath>/path/to/doccheck.jar</docletPath> -->
              <docletArtifact>
                <groupId>com.sun.tools.doclets</groupId>
                <artifactId>doccheck</artifactId>
                <version>1.2b2</version>
              </docletArtifact>
              <additionalparam>
                    -d ${project.build.directory}/site/doccheck
              </additionalparam>

              <!-- Other dir than apidocs -->
              <destDir>doccheck</destDir>

              <!-- For the project-reports page-->
              <name>DocCheck</name>
              <description>DocCheck documentation.</description>
            </configuration>
            <reports>
              <report>javadoc</report>
            </reports>
          </reportSet>
        </reportSets>
      </plugin>
      ...
    </plugins>
  </reporting>
  ...
</project>