I have a question very similar to Javadocs are not appearing on Apache netbeans for java 10 in the sense that I can't seem to add javadoc support to my Apache Netbeans 11 release, or the maven project that I'm working on.
Here is the overview that I have:
As you can see, the javadoc is added in the URL section, but it does not appear in the code editor, even after a restart.
The URL I added: https://docs.oracle.com/en/java/javase/11/docs/api/index.html
But this doesn't work.
How can I resolve this?
I've yet to see somebody who managed to add Javadoc 11 to Netbeans 11.
But there's a work-around which seems to work for many JDK classes, but not for all. If anybody knows how to solve the problem for all JDK classes, please say so, thanks.
Here's the workaround, doing well under Ubuntu 18 Linux with Openjdk11 from the Ubuntu repository, and probably also under other platforms:
Firstly it's strange how we have to add the Javadoc at all. In NB's menu Tools → Java Platforms there's a tab Sources and Javadoc.
1) I tried to use the tab Javadoc first, and had to add all the folders beginning with "java." from the main folder "javadoc/api/" from an unzipped Javadoc11 bundle. This way some JDK functions show the correct Javadoc pop-up help, however many functions just show an empty space, like for example when in Netbeans I enter:
BigInteger big;
big. _
Then the pop-up comes and lists all BigInteger functions but their Javadoc is empty each.
So I tried another approach:
2) From the same NB menu Tools → Java Platforms in the tab Javadoc I removed all entries, and used the other tab Sources where I added all the folders beginning with "java." from an unzipped Java11 source bundle (file src.zip).
This way for many more JDK classes and functions their pop-up window works fine, like the mentioned BigInterger one.
However for certain classes from the java.sql package and probably from others, too, I can't make it to work. For example I enter in NB:
java.sql.Statement stat;
stat. _
Then I get a pop-up listing all functions, but for many there's a message Javadoc not found in the pop-up window. Like these functions:
stat.addBatch(…)
stat.execute(…)
stat.executeUpdate(…)
etc.
For the following functions however the pop-up window shows the correct Javadoc:
stat.cancel(…)
stat.close(…)
stat.executeBatch(…)
etc.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With