Blog

  • 2024
  • 2023
  • 2022
  • 2021
  • 2020
  • 2019
  • 2018
  • 2017
  • 2016
  • 2015
  • 2014
  • 2013
  • 2012




There are a couple of tools that allow to produce appealing API documentation with Javadoc.

The taglets library is one of them.

Using taglets

The taglets library has defined a couple of visually attractive taglets that allow to highlight important information within an API or even render Java source code (e.g. for example usage scenarios). Here is an example from the API documentation of one of our projects (it shows an element of an annotation):

Maven Configuration

To integrate this in your Maven build, use this configuration for the Maven Javadoc Plugin:

<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-javadoc-plugin</artifactId>
  <configuration>
    ...
    <taglets>
      <taglet>
        <tagletClass>net.sourceforge.taglets.Taglets</tagletClass>
        <tagletArtifact>
          <groupId>net.sourceforge.taglets</groupId>
          <artifactId>taglets</artifactId>
          <version>2.0.3</version>
        </tagletArtifact>
      </taglet>
    </taglets>
    ...
  </configuration>
</plugin>

This snippet shows only the relevant part for the integration of the taglets library. The artifact can be found on our Nexus server.

References and other Resources


Link

Link

Posts