The taglets can be used directly in the Maven Javadoc Plugin.
<project> ... <reporting> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-javadoc-plugin</artifactId> <version>2.6</version> <configuration> <!-- To allow Javadoc Tool to generate annotation for Mojo fields --> <show>private</show> <tagletArtifacts> <tagletArtifact> <groupId>org.apache.maven.plugin-tools</groupId> <artifactId>maven-plugin-tools-javadoc</artifactId> <version>3.3</version> </tagletArtifact> </tagletArtifacts> ... </configuration> </plugin> </plugins> ... </reporting> ... </project>
Note: Several taglets are similar to simple Javadoc -tag options, i.e.:
Taglet Class | Javadoc -tag option |
---|---|
MojoAggregatorTypeTaglet | -tag 'aggregator:t:Aggregates the Maven project and its child modules.' |
MojoComponentFieldTaglet | none |
MojoConfiguratorTypeTaglet | -tag 'configurator:t:Is configured to the role hint:' |
MojoExecuteTypeTaglet | none |
MojoExecutionStrategyTypeTaglet | -tag 'executionStrategy:t:Is executed with the strategy:' |
MojoGoalTypeTaglet | -tag 'goal:t:This Mojo is defined by the goal name:' |
MojoInheritByDefaultTypeTaglet | -tag 'inheritByDefault:t:Is this Mojo inherited' |
MojoInstantiationStrategyTypeTaglet | -tag 'instantiationStrategy:t:Is instantiated with the strategy:' |
MojoParameterFieldTaglet | none |
MojoPhaseTypeTaglet | -tag 'phase:t:Is binded to the specified phase of the standard build lifecycle:' |
MojoReadOnlyFieldTaglet | -tag 'readonly:f:Is readonly.' |
MojoRequiredFieldTaglet | -tag 'required:f:Is required.' |
MojoRequiresDependencyResolutionTypeTaglet | -tag 'requiresDependencyResolution:t:Requires the dependencies in this specified scope:' |
MojoRequiresDirectInvocationTypeTaglet | -tag 'requiresDirectInvocation:t:Requires a direct invocation by the user' |
MojoRequiresOnLineTypeTaglet | -tag 'requiresProject:t:Requires to be online to run' |
MojoRequiresProjectTypeTaglet | -tag 'requiresProject:t:Requires a Maven project to run' |
MojoRequiresReportsTypeTaglet | -tag 'requiresReports:t:Requires Maven reports to run' |