Attaching additional javadoc in Intellij IDEA

JavaIntellij IdeaJavadoc

Java Problem Overview


When I use quick documentaion lookup (Ctrl+Q) on j2ee classes or annotations in IDEA I only get an empty javadoc. It only contains the basics like class name.

How do I add the javadoc to the libs IDEA provides itself?

Java Solutions


Solution 1 - Java

You can attach javadoc to any library you have configure in your module or project. Just access the project structure windows (File -> Project Structure), then select "modules" and select the module that has the dependency you want to configure.

Then select the "Dependencies" tab, select the dependency that's missing the javadoc and click "Edit". In the window that just showed up you see two buttons "Add" and "Specify Javadoc URL". If you have the javadoc in a jar file select the first one, if you want to point to a web site that contains the javadoc select the latest. That's it.

Solution 2 - Java

If using maven:

"right click on your pom.xml" -> "Maven" -> then choose "Download Sources and Documentation"

To avoid this in the future: "Preferences" -> "Build, Execution, Deployment" -> "Build Tools" -> "Maven" -> "Importing" -> Check the Automatically download Sources and Documentation boxes.

Credit to Yacov Schondorf and Stephen Boesch from Intellij user forums.

Solution 3 - Java

What about documentation for an extension API? I had added the j3d API to my jdk1.6 and use it succesfully, next step, get the javadoc

Forget the links on java.sun.com (It is a mess) Go directly to java.net and get all the stuff (API, javadoc, get the source even -for every package-)

Go to your jdk and selected the documentation path and add the javadoc zip. Go to the source tab and add the source's zip

You're done.

Actually only the source is needed to enjoy javadoc and the uncompiled classes

Solution 4 - Java

right click on the maven pom.xml -> "Maven" ->Download documentation,wait for a sec,you'll make it!

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionhomaxtoView Question on Stackoverflow
Solution 1 - JavaHugo PalmaView Answer on Stackoverflow
Solution 2 - JavaJMessView Answer on Stackoverflow
Solution 3 - JavaalbfanView Answer on Stackoverflow
Solution 4 - Javaoneslide icywaterView Answer on Stackoverflow