This goal should be used as a Maven report.
Generates documentation for the Java code
in a NON aggregator project using the standard Javadoc Tool.
See also: Javadoc Tool
Specifies the path of an additional HTML stylesheet file relative to the
javadocDirectory
Example:
<addStylesheets> <addStylesheet>resources/addstylesheet.css</addStylesheet> </addStylesheets>
java.lang.String[]
3.3.0
No
Capability to add additional dependencies to the javadoc classpath. Example:
<additionalDependencies> <additionalDependency> <groupId>geronimo-spec</groupId> <artifactId>geronimo-spec-jta</artifactId> <version>1.0.1B-rc4</version> </additionalDependency> </additionalDependencies>
java.util.List<org.apache.maven.plugins.javadoc.AdditionalDependency>
2.8.1
No
java.lang.String
2.3
No
additionalJOption
Sets additional Javadoc options for the execution of the javadoc command via the '-J' option to javadoc. Example:
<additionalJOptions> <additionalJOption>-J-Xmx1g </additionalJOption> </additionalJOptions>
java.lang.String[]
2.9
No
Set an additional option(s) on the command line. All input will be passed as-is to the @options
file. You must take care of quoting and escaping. Useful for a custom doclet.
java.lang.String[]
3.0.0
No
Deprecated.
the security fix this applied is not needed in Java 8+ or the most recent versions of JDK 6 and 7.
No-op.
boolean
2.9.1
No
maven.javadoc.applyJavadocSecurityFix
true
Specifies whether or not the author text is included in the generated Javadocs.
.
boolean
No
author
true
Specifies the paths where the boot classes reside. The
bootclasspath
can contain multiple paths by separating them with a colon (
:
) or a semicolon (
;
).
.
java.lang.String
2.5
No
bootclasspath
Specifies the artifacts where the boot classes reside.
Example:
<bootclasspathArtifacts> <bootclasspathArtifact> <groupId>my-groupId</groupId> <artifactId>my-artifactId</artifactId> <version>my-version</version> </bootclasspathArtifact> </bootclasspathArtifacts>
See
Javadoc.
org.apache.maven.plugins.javadoc.options.BootclasspathArtifact[]
2.5
No
bootclasspathArtifacts
Specifies the text to be placed at the bottom of each output file.
If you want to use html, you have to put it in a CDATA section,
e.g.
<![CDATA[Copyright 2005, <a href="http://www.mycompany.com">MyCompany, Inc.<a>]]>
project.build.outputTimestamp
, its year will be used as {currentYear}. This way it is possible to generate reproducible javadoc jars.
.
java.lang.String
No
bottom
Copyright © {inceptionYear}–{currentYear} {organizationName}. All rights reserved.
boolean
No
breakiterator
false
Specifies the HTML character set for this document. If not specified, the charset value will be the value of the
docencoding
parameter.
.
java.lang.String
No
charset
Set this to true
to debug the Javadoc plugin. With this, javadoc.bat(or.sh)
, options
, @packages
or argfile
files are provided in the output directory.
boolean
2.1
No
debug
false
Redefine the apidoc URL for specific dependencies when using
detectLinks
. Useful if the dependency wasn't build with Maven or when the apidocs have been moved.
<dependencyLinks> <dependencyLink> <groupId>groupId</groupId> <artifactId>artifactId</artifactId> <classifier>classifier</classifier> <!-- optional --> <url>version</url> </dependencyLink> </dependencyLinks>
java.util.List<org.apache.maven.plugins.javadoc.DependencyLink>
3.3.0
No
java.util.List<java.lang.String>
2.7
No
java.util.List<java.lang.String>
2.7
No
The description of the Javadoc report to be displayed in the Maven Generated Reports page (i.e. project-reports.html
).
java.lang.String
2.1
No
description
Detect the Java API link for the current build, e.g.
https://docs.oracle.com/javase/1.4.2/docs/api/
for Java source 1.4.
By default, the goal detects the Javadoc API link depending the value of the
source
parameter in the
org.apache.maven.plugins:maven-compiler-plugin
(defined in
${project.build.plugins}
or in
${project.build.pluginManagement}
), or try to compute it from the
javadocExecutable
version.
,
javaApiLinksboolean
2.6
No
detectJavaApiLink
true
Detect the Javadoc links for all dependencies defined in the project. The detection is based on the default Maven conventions, i.e.:
${project.url}/apidocs
.
For instance, if the project has a dependency to
Apache Commons Langi.e.:
<dependency> <groupId>commons-lang</groupId> <artifactId>commons-lang</artifactId> </dependency>
The added Javadoc
-link
parameter will be
http://commons.apache.org/lang/apidocs
.
,
dependencyLinksboolean
2.6
No
detectLinks
false
Detect the links for all modules defined in the project.
If
reactorProjects
is defined in a non-aggregator way, it generates default offline links between modules based on the defined project's urls. For instance, if a parent project has two projects
module1
and
module2
, the
-linkoffline
will be:
The added Javadoc
-linkoffline
parameter for
module1will be
/absolute/path/to/
module2/target/site/apidocs
The added Javadoc
-linkoffline
parameter for
module2will be
/absolute/path/to/
module1/target/site/apidocs
boolean
2.6
No
detectOfflineLinks
true
From jdk 23, javadoc now include some extra css, files which can increase the size of javadoc jar. This can be disabled using the option --no-fonts
The javadoc plugin will add this option to disable extra files to be added per default. If you prefer the new font you must set to true
the option disableNoFonts
boolean
3.11.3
No
maven.javadoc.disableNoFonts
false
When using legacyMode and aggregated javadoc, users may have a mix of Maven modules with module files and not. The javadoc need to be called with empty
-sourcepath
argument and files are in the argfile This usually need to be used with the following configuration
<sourceFileExcludes>
<sourceFileExclude>**\/module-info.java</sourceFileExclude>
</sourceFileExcludes>
boolean
3.11.2
No
maven.javadoc.disableSourcepathUsage
Specifies the encoding of the generated HTML files. If not specified, the docencoding value will be
UTF-8
.
.
java.lang.String
No
docencoding
${project.reporting.outputEncoding}
boolean
No
docfilessubdirs
false
Specifies the class file that starts the doclet used in generating the documentation.
.
java.lang.String
No
doclet
Specifies the artifact containing the doclet starting class file (specified with the
doclet
option).
Example:
<docletArtifact> <groupId>com.sun.tools.doclets</groupId> <artifactId>doccheck</artifactId> <version>1.2b2</version> </docletArtifact>
See
Javadoc.
See also: Javadoc option docletpath.
org.apache.maven.plugins.javadoc.options.DocletArtifact
No
docletArtifact
Specifies multiple artifacts containing the path for the doclet starting class file (specified with the
doclet
option).
Example:
<docletArtifacts> <docletArtifact> <groupId>com.sun.tools.doclets</groupId> <artifactId>doccheck</artifactId> <version>1.2b2</version> </docletArtifact> </docletArtifacts>
See
Javadoc.
See also: Javadoc option docletpath.
org.apache.maven.plugins.javadoc.options.DocletArtifact[]
2.1
No
docletArtifacts
Specifies the path to the doclet starting class file (specified with the
doclet
option) and any jar files it depends on. The
docletPath
can contain multiple paths by separating them with a colon (
:
) or a semicolon (
;
).
.
java.lang.String
No
docletPath
java.lang.String
3.0.0
No
doclint
Specifies the title to be placed near the top of the overview summary file.
.
java.lang.String
No
doctitle
${project.name} ${project.version} API
Specifies the encoding name of the source files. If not specified, the encoding value will be the value of the
file.encoding
system property.
: In 2.4, the default value was locked to
ISO-8859-1
to ensure reproducing build, but this was reverted in 2.5.
.
java.lang.String
No
encoding
${project.build.sourceEncoding}
Unconditionally excludes the specified packages and their subpackages from the list formed by
-subpackages
. Multiple packages can be separated by commas (
,
), colons (
:
) or semicolons (
;
).
Wildcards work as followed:
Example:
<excludePackageNames>*.internal:org.acme.exclude1.*:org.acme.exclude2</excludePackageNames>
.
java.lang.String
No
excludePackageNames
java.lang.String
No
excludedocfilessubdir
Specifies the directories where extension classes reside. Separate directories in
extdirs
with a colon (
:
) or a semicolon (
;
).
.
java.lang.String
No
extdirs
Specifies if the build will fail if there are errors during javadoc execution or not.
boolean
2.5
No
maven.javadoc.failOnError
true
Specifies if the build will fail if there are warning during javadoc execution or not.
boolean
3.0.1
No
maven.javadoc.failOnWarnings
false
Specifies the footer text to be placed at the bottom of each output file.
.
java.lang.String
No
footer
Forces the Javadoc JVM locale to be
java.util.Locale.ROOT
. This will force the Javadoc output on
stdout
and
stderr
to be in English only and the generated HTML content in English as well. If you need the generated HTML content in another supported language use
locale
.
boolean
3.8.0
No
forceRootLocale
true
Separates packages on the overview page into whatever groups you specify, one group per table. The packages pattern can be any package name, or can be the start of any package name followed by an asterisk (
*
) meaning "match any characters". Multiple patterns can be included in a group by separating them with colons (
:
).
Example:
<groups> <group> <title>Core Packages</title> <!-- To includes java.lang, java.lang.ref, java.lang.reflect and only java.util (i.e. not java.util.jar) --> <packages>java.lang*:java.util</packages> </group> <group> <title>Extension Packages</title> <!-- To include javax.accessibility, javax.crypto, ... (among others) --> <packages>javax.*</packages> </group> </groups>Note
: using
java.lang.*
for
packages
would omit the
java.lang
package but using
java.lang*
will include it.
.,
org.apache.maven.plugins.javadoc.options.Grouporg.apache.maven.plugins.javadoc.options.Group[]
No
Specifies the header text to be placed at the top of each output file.
.
java.lang.String
No
header
Specifies the path of an alternate help file path\filename that the HELP link in the top and bottom navigation bars link to.
: could be in conflict with <nohelp/>.
The
helpfile
could be an absolute File path.
Since 2.6, it could be also be a path from a resource in the current project source directories (i.e.
src/main/java
,
src/main/resources
or
src/main/javadoc
) or from a resource in the Javadoc plugin dependencies, for instance:
<helpfile>path/to/your/resource/yourhelp-doc.html</helpfile>
Where
path/to/your/resource/yourhelp-doc.html
could be in
src/main/javadoc
.
<build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-javadoc-plugin</artifactId> <configuration> <helpfile>path/to/your/resource/yourhelp-doc.html</helpfile> ... </configuration> <dependencies> <dependency> <groupId>groupId</groupId> <artifactId>artifactId</artifactId> <version>version</version> </dependency> </dependencies> </plugin> ... <plugins> </build>
Where
path/to/your/resource/yourhelp-doc.html
is defined in the
groupId:artifactId:version
javadoc plugin dependency.
.
java.lang.String
No
helpfile
Whether dependency -sources jars should be resolved and included as source paths for javadoc generation. This is useful when creating javadocs for a distribution project.
boolean
2.7
No
false
Deprecated.
if these sources depend on transitive dependencies, those dependencies should be added to the pom as direct dependencies
Whether to include transitive dependencies in the list of dependency -sources jars to include in this javadoc run.
boolean
2.7
No
false
Use this parameter
onlyif if you want to override the default URLs. The key should match
api_x
, where
x
matches the Java version. For example:
java.util.Properties
2.6
No
javaApiLinks
Specifies the Javadoc resources directory to be included in the Javadoc (i.e. package.html, images...).
Could be used in addition of
docfilessubdirs
parameter.
See
docfilessubdirs.
java.io.File
2.1
No
${basedir}/src/main/javadoc
Sets the absolute path of the Javadoc Tool executable to use. Since version 2.5, a mere directory specification is sufficient to have the plugin use "javadoc" or "javadoc.exe" respectively from this directory.
java.lang.String
2.3
No
javadocExecutable
Version of the Javadoc Tool executable to use, ex. "1.3", "1.5".
java.lang.String
2.3
No
javadocVersion
Allow for configuration of the javadoc tool via maven toolchains. This overrules the toolchain selected by the maven-toolchain-plugin.
Examples:
(see
Guide to Toolchainsfor more info)
<configuration>
...
<jdkToolchain>
<version>11</version>
</jdkToolchain>
</configuration>
<configuration>
...
<jdkToolchain>
<version>1.8</version>
<vendor>zulu</vendor>
</jdkToolchain>
</configuration>
note:
requires at least Maven 3.3.1
java.util.Map<java.lang.String, java.lang.String>
3.0.0
No
boolean
2.1
No
keywords
false
Run the javadoc tool in pre-Java 9 (non-modular) style even if the java version is post java 9. This allows non-JPMS projects that have moved to newer Java versions to create javadocs without having to use JPMS modules.
boolean
3.6.0
No
legacyMode
false
Creates links to existing javadoc-generated documentation of external referenced classes.
Notes:
<offline>
setting or specifying -o, --offline
or -Dmaven.javadoc.offline=true
on the command line./package-list
or /element-list
(since Java 10). For instance:
<links> <link>https://docs.oracle.com/en/java/javase/17/docs/api</link> </links>will be used because
https://docs.oracle.com/en/java/javase/17/docs/api/element-list
exists.detectLinks
is defined, the links between the project dependencies are automatically added.detectJavaApiLink
is defined, a Java API link, based on the Java version of the project's sources, will be added automatically.java.util.ArrayList<java.lang.String>
No
links
Creates an HTML version of each source file (with line numbers) and adds links to them from the standard HTML documentation.
boolean
No
linksource
false
java.lang.String
No
locale
Specifies the maximum Java heap size to be used when launching the Javadoc tool. JVMs refer to this property as the -Xmx
parameter. Example: '512' or '512m'. The memory unit depends on the JVM used. The units supported could be: k
, kb
, m
, mb
, g
, gb
, t
, tb
. If no unit specified, the default unit is m
.
java.lang.String
No
maxmemory
Specifies the minimum Java heap size to be used when launching the Javadoc tool. JVMs refer to this property as the -Xms
parameter. Example: '512' or '512m'. The memory unit depends on the JVM used. The units supported could be: k
, kb
, m
, mb
, g
, gb
, t
, tb
. If no unit specified, the default unit is m
.
java.lang.String
No
minmemory
The name of the Javadoc report to be displayed in the Maven Generated Reports page (i.e. project-reports.html
).
java.lang.String
2.1
No
name
Suppress the entire comment body, including the main description and all tags, generating only declarations.
.
boolean
No
nocomment
false
boolean
No
nodeprecated
false
Prevents the generation of the file containing the list of deprecated APIs (deprecated-list.html) and the link in the navigation bar to that page.
.
boolean
No
nodeprecatedlist
false
Omits the HELP link in the navigation bars at the top and bottom of each page of output.
: could be in conflict with
helpfile
.
.
boolean
No
nohelp
false
boolean
No
noindex
false
boolean
No
nonavbar
false
Omits the entire overview page from the generated docs.
: could be in conflict with
overview
.
Standard Doclet undocumented option.
boolean
2.4
No
nooverview
false
Omits qualifying package name from ahead of class names in output. Example:
<noqualifier>all</noqualifier> or <noqualifier>packagename1:packagename2</noqualifier>
.
java.lang.String
No
noqualifier
Omits from the generated docs the "Since" sections associated with the since tags.
.
boolean
No
nosince
false
Suppresses the timestamp, which is hidden in an HTML comment in the generated HTML near the top of each page.
Note: If the project has the property project.build.outputTimestamp
, the value will be overwritten to true. This way it is possible to generate reproducible javadoc jars.
.
boolean
2.1
No
notimestamp
false
boolean
No
notree
false
Specify if the Javadoc plugin should operate in offline mode. If maven is run in offline mode (using -o
or --offline
on the command line), this option has no effect and the plugin is always in offline mode.
boolean
3.6.0
No
maven.javadoc.offline
false
This option is a variation of
links
; they both create links to javadoc-generated documentation for external referenced classes.
Example:
<offlineLinks> <offlineLink> <url>https://docs.oracle.com/javase/1.5.0/docs/api/</url> <location>../javadoc/jdk-5.0/</location> </offlineLink> </offlineLinks>
: if
detectOfflineLinks
is defined, the offline links between the project modules are automatically added if the goal is calling in a non-aggregator way.
,
Doclet option linkofflineorg.apache.maven.plugins.javadoc.options.OfflineLink[]
No
offlineLinks
Deprecated.
No reason given
This option creates documentation with the appearance and functionality of documentation generated by Javadoc 1.1. This is no longer supported since Javadoc 1.4 (shipped with JDK 1.4)
.
boolean
No
old
false
The shared output directory for the report where Javadoc saves the generated HTML files. Note that this parameter is only evaluated if the goal is run directly from the command line. If the goal is run indirectly as part of a site generation, the shared output directory configured in the
Maven Site Pluginis used instead.
org.apache.maven.reporting.AbstractMavenReport.outputDirectory,
Doclet option djava.io.File
Yes
${project.build.directory}/reports
Timestamp for reproducible output archive entries, either formatted as ISO 8601
yyyy-MM-dd'T'HH:mm:ssXXX
or as an int representing seconds since the epoch (like
SOURCE_DATE_EPOCH).
java.lang.String
3.2.0
No
${project.build.outputTimestamp}
Specifies that javadoc should retrieve the text for the overview documentation from the "source" file specified by path/filename and place it on the Overview page (overview-summary.html).
: could be in conflict with
nooverview
.
.
java.io.File
No
overview
${basedir}/src/main/javadoc/overview.html
java.lang.String
2.1
No
packagesheader
Shuts off non-error and non-warning messages, leaving only the warnings and errors appear, making them easier to view.
Note: was a standard doclet in Java 1.4.2 (refer to bug ID
4714350).
Since Java 5.0.
.
boolean
No
quiet
false
java.lang.String
JDK 9
No
${maven.compiler.release}
A list of artifacts containing resources which should be copied into the Javadoc output directory (like stylesheets, icons, etc.).
Example:
<resourcesArtifacts> <resourcesArtifact> <groupId>external.group.id</groupId> <artifactId>external-resources</artifactId> <version>1.0</version> </resourcesArtifact> </resourcesArtifacts>
See
Javadoc.
org.apache.maven.plugins.javadoc.options.ResourcesArtifact[]
2.5
No
resourcesArtifacts
boolean
No
serialwarn
false
Specifies the access level for classes and members to show in the Javadocs. Possible values are:
java.lang.String
No
show
protected
Specifies whether the Javadoc generation should be skipped.
boolean
2.5
No
maven.javadoc.skip
false
Comma separated list of modules (can be regular expression) in the format ([group:]artifactId) to not add in aggregated javadoc
java.lang.String
3.2.0
No
maven.javadoc.skippedModules
java.lang.String
No
source
${maven.compiler.source}
java.io.File
2.7
No
${project.build.directory}/distro-javadoc-sources
exclude filters on the source files. These are ignored if you specify subpackages or subpackage excludes.
java.util.List<java.lang.String>
2.9
No
Include filters on the source files. Default is **\/\*.java. These are ignored if you specify subpackages or subpackage excludes.
java.util.List<java.lang.String>
2.9
No
Specifies the source paths where the subpackages are located. The
sourcepath
can contain multiple paths by separating them with a colon (
:
) or a semicolon (
;
).
.
java.lang.String
No
sourcepath
Specify the number of spaces each tab takes up in the source. If no tab is used in source, the default space is used.
int
2.1
No
sourcetab
linksourcetab
Splits the index file into multiple files, alphabetically, one file per letter, plus a file for any index entries that start with non-alphabetical characters.
: could be in conflict with
noindex
.
.
boolean
No
splitindex
false
Location of the file used to store the state of the previous javadoc run. This is used to skip the generation if nothing has changed.
java.io.File
3.2.0
No
staleDataPath
${project.build.directory}/maven-javadoc-plugin-stale-data.txt
This is no longer evaluated, instead use
addStylesheets
to customize the CSS.
Specifies whether the stylesheet to be used is the
maven
's javadoc stylesheet or
java
's default stylesheet when a
stylesheetfile
parameter is not specified.
Possible values:
maven or java
.
java.lang.String
No
stylesheet
java
Specifies the path of an alternate HTML stylesheet file.
The
stylesheetfile
could be an absolute File path.
Since 2.6, it could be also be a path from a resource in the current project source directories (i.e.
src/main/java
,
src/main/resources
or
src/main/javadoc
) or from a resource in the Javadoc plugin dependencies, for instance:
<stylesheetfile>path/to/your/resource/yourstylesheet.css</stylesheetfile>
Where
path/to/your/resource/yourstylesheet.css
could be in
src/main/javadoc
.
<build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-javadoc-plugin</artifactId> <configuration> <stylesheetfile>path/to/your/resource/yourstylesheet.css</stylesheetfile> ... </configuration> <dependencies> <dependency> <groupId>groupId</groupId> <artifactId>artifactId</artifactId> <version>version</version> </dependency> </dependencies> </plugin> ... <plugins> </build>
Where
path/to/your/resource/yourstylesheet.css
is defined in the
groupId:artifactId:version
javadoc plugin dependency.
.
java.lang.String
No
stylesheetfile
Specifies the package directory where javadoc will be executed. Multiple packages can be separated by colons (
:
).
.
java.lang.String
No
subpackages
Specifies the class file that starts the taglet used in generating the documentation for that tag.
.
java.lang.String
No
taglet
Specifies the Taglet artifact containing the taglet class files (.class).
Example:
<taglets> <taglet> <tagletClass>com.sun.tools.doclets.ToDoTaglet</tagletClass> </taglet> <taglet> <tagletClass>package.to.AnotherTagletClass</tagletClass> </taglet> ... </taglets> <tagletArtifact> <groupId>group-Taglet</groupId> <artifactId>artifact-Taglet</artifactId> <version>version-Taglet</version> </tagletArtifact>
See
Javadoc.
.
org.apache.maven.plugins.javadoc.options.TagletArtifact
2.1
No
tagletArtifact
Specifies several Taglet artifacts containing the taglet class files (.class). These taglets class names will be auto-detect and so no need to specify them.
Example:
<tagletArtifacts> <tagletArtifact> <groupId>group-Taglet</groupId> <artifactId>artifact-Taglet</artifactId> <version>version-Taglet</version> </tagletArtifact> ... </tagletArtifacts>
See
Javadoc.
org.apache.maven.plugins.javadoc.options.TagletArtifact[]
2.5
No
tagletArtifacts
Specifies the search paths for finding taglet class files (.class). The
tagletpath
can contain multiple paths by separating them with a colon (
:
) or a semicolon (
;
).
.
java.lang.String
No
tagletpath
Enables the Javadoc tool to interpret multiple taglets.
Example:
<taglets> <taglet> <tagletClass>com.sun.tools.doclets.ToDoTaglet</tagletClass> <!--<tagletpath>/home/taglets</tagletpath>--> <tagletArtifact> <groupId>group-Taglet</groupId> <artifactId>artifact-Taglet</artifactId> <version>version-Taglet</version> </tagletArtifact> </taglet> </taglets>
See
Javadoc.
See also: Doclet options taglet and tagletpath
org.apache.maven.plugins.javadoc.options.Taglet[]
2.1
No
taglets
Enables the Javadoc tool to interpret a simple, one-argument custom block tag tagname in doc comments.
Example:
<tags> <tag> <name>todo</name> <placement>a</placement> <head>To Do:</head> </tag> </tags>Note
: the placement should be a combinaison of Xaoptcmf letters:
X
(disable tag)a
(all)o
(overview)p
(packages)t
(types, that is classes and interfaces)c
(constructors)m
(methods)f
(fields)See
Javadoc.
.
org.apache.maven.plugins.javadoc.options.Tag[]
No
tags
java.lang.String
2.4
No
top
Includes one "Use" page for each documented class and package.
.
boolean
No
use
true
Specifies to use the
options provided by the Standard Docletfor a custom doclet.
Example:
<docletArtifacts> <docletArtifact> <groupId>com.sun.tools.doclets</groupId> <artifactId>doccheck</artifactId> <version>1.2b2</version> </docletArtifact> </docletArtifacts> <useStandardDocletOptions>true</useStandardDocletOptions>
boolean
2.5
No
useStandardDocletOptions
true
Flag controlling content validation of package-list
/element-list
resources. If set, the content of package-list
/element-list
resources will be validated.
boolean
2.8
No
validateLinks
false
boolean
No
verbose
false
boolean
No
version
true
java.lang.String
No
windowtitle
${project.name} ${project.version} API
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4