I am using same command to generate javadoc with jdk 1.8 and 1.9 while doc gets generated with errors and warning in jdk 1.8 but is not getting generated with 1.9.
Below is the command I am using:-
C:\Program Files\Java\jdk1.8.0_05\bin>javadoc -d D:\APIdoc -sourcepath D:\MyFile\src\main\java -subpackages com.abc.dap.pqr
Output:
100 errors
100 warnings
Doc generated successfully
C:\Program Files\Java\jdk-9\bin>javadoc -d D:\APIdoc1 -sourcepath D:\MyFile\src\main\java -subpackages com.abc.dap.pqr
Output:
100 errors
Doc not generated
Below are the errors:-
error: package [package_name] does not exist
error: cannot find symbol
Same errors are observed in jdk1.8 and 1.9 but I am unable to understand why doc is not generated with 1.9. Please suggest workaround for generating javadoc with jdk1.9
You may have better luck by turning off some of the checks using
-Xdoclint:-<group>, particularly-Xdoclint:-referencewhich will cause it to ignore issues relating to the references to Java API elements from Javadoc tags, or even-Xdoclint:noneto turn off all checks. If that doesn't help, you can invoke the legacy javadoc tool with-Xold.See
javadoc -Xor the javadoc documentation for more information.