Open nhumblot opened 4 years ago
Comment from @xhanin in #318 regarding ApidocsDoclet.validOptions(String[][] options, DocErrorReporter errorReporter)
removal, telling maintainer's vision on how to address this issue:
It seems that this will prevent the doclet from working with options on java 8 and java 9. As stated here: https://docs.oracle.com/javase/8/docs/jdk/api/javadoc/doclet/com/sun/javadoc/Doclet.html
This method is required by the Doclet api to accept options.
Maybe a better option would be to have a new module restx-apidocs-doclet-11 compatible with doclet api 11, and keeping this module compatible with java < 11.
The new doclet api is documented here: https://openjdk.java.net/groups/compiler/using-new-doclet.html
It has a brand new way to deal with options.
restx-apidocs-doclet
has some breaking changes when using a jdk11.pom.xml
First issue is located in the
pom.xml
. The following dependency cannot be imported due totools.jar
removal:ApidocsDoclet.java
Removing this dependency (or not having it for java11) generates one error into the module in
ApidocsDoclet.java
, due to the call toStandard.validOptions(options, errorReporter)
at line 182. This method has been deprecated in Java 9 and removed in Java 10. The underlying classHtmlDoclet.java
has been removed as well.Its goal is to validate potential parameters passed to the javadoc command. Options for jdk8 can be found here: https://docs.oracle.com/javase/8/docs/technotes/tools/unix/javadoc.html
I couldn't find any exhaustive documentation about parameters available for the new javadoc command except from the tool itself:
ApidocsDocletRunner.java
To make the
javadoc
command work with jdk11, we will also have to changeApidocsDocletRunner.run()
method so it generates valid arguments based on the java version.The
-d
parameter seems to be the only issue ? To be confirmed.