jdk.javadoc/jdk.javadoc.internal.tool.Main - "javadoc" Command

Q

How to run "javadoc" command from JDK lib\modules JImage file?

✍: FYIcenter

A

"javadoc" command allows you to generate Java documentation in HTML format from Java source code files.

"javadoc" command is supported by the jmods\jdk.javadoc.jmod module file, which is also linked into the lib\modules JImage file.

You can run the "javadoc" command using the lib\modules JImage file as described below:

fyicenter> %JDK_HOME%\bin\java --module jdk.javadoc/jdk.javadoc.internal.tool.Main -help

Usage: javadoc [options] [packagenames] [sourcefiles] [@files]
  -overview <file>                 Read overview documentation from HTML file
  -public                          Show only public classes and members
  -protected                       Show protected/public classes and members (default)
  -package                         Show package/protected/public classes and members
  -private                         Show all classes and members
  -help                            Display command line options and exit
  -doclet <class>                  Generate output via alternate doclet
  -docletpath <path>               Specify where to find doclet class files
  --module-source-path <path>      Specify where to find input source files 
                                   for multiple modules
  --upgrade-module-path <path>     Override location of upgradeable modules
  --module-path <path>, -p <path>  Specify where to find application modules
  --add-modules <module>(,<module>)*
                                   Root modules to resolve in addition to the 
                                   initial modules,
                                   or all modules on the module path if <module> 
                                   is ALL-MODULE-PATH.
  --limit-modules <module>(,<module>)*
                                   Limit the universe of observable modules
  --source-path <path>             Specify where to find source files
  -sourcepath <path>               Specify where to find source files
  --class-path <path>              Specify where to find user class files
  -classpath <path>                Specify where to find user class files
  -cp <path>                       Specify where to find user class files
  -exclude <pkglist>               Specify a list of packages to exclude
  -subpackages <subpkglist>        Specify subpackages to recursively load
  -breakiterator                   Compute first sentence with BreakIterator
  -bootclasspath <path>            Override location of platform class files
                                   used for non-modular releases
  --system <jdk>                   Override location of system modules used
                                   for modular releases.
  -source <release>                Provide source compatibility with specified release
  --release <release>              Provide source compatibility with specified release
  -extdirs <dirlist>               Override location of installed extensions
  -verbose                         Output messages about what Javadoc is doing
  -locale <name>                   Locale to be used, e.g. en_US or en_US_WIN
  -encoding <name>                 Source file encoding name
  -quiet                           Do not display status messages
  -J<flag>                         Pass <flag> directly to the runtime system
  -X                               Print a synopsis of nonstandard options and exit

GNU-style options may use = instead whitespace to separate the name of an option
from its value.

 

jdk.jcmd/sun.tools.jcmd.JCmd - "jcmd" Command

jdk.javadoc/com.sun.tools.javadoc.Main - "javadoc" Command

Tools Supported from JDK 9+ lib\modules JImage

⇑⇑ FAQ for JDK (Java Development Kit)

2019-08-23, 1387🔥, 0💬