Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to show scala doc from Java Editor in Eclipse?

I'm using the Akka Java API together with Eclipse (Kepler Service Release 2) + Maven. I can jump right into the scala class from the Java Editor, but I'm not able to see the documentation on hover (see example picture). Is there any way to include the documentation on hover?

On hover:

Empty Hover Documentation

The documentation it should display:

Correct Documentation

like image 446
Flori Avatar asked Jun 23 '14 09:06

Flori


People also ask

How do I display javadoc in Eclipse?

To see the javadoc of a class having attached source in eclipse: select Window -> show view -> javadoc (or alt + shift + q, j). then in the javadoc view, right click -> open attached javadoc (or shift + F2), this will display the javadoc of the class in the internal browser of eclipse.

How do I show documents in eclipse?

Yes pressing F2 will open documentation.

How do I enable Java documentation in Eclipse?

Step 1 − Open eclipse, select the option Project →Generate Javadoc. Step 2 − Select the javadoc.exe file from the bin folder of java installation directory, select the destination folder for the generated java doc and select Next. finish button.


1 Answers

When using maven convention, a library is bundled as 'group.artifact.version.jar' for binary, 'group.artifact.version-sources.jar' for source code and 'group.artifact.version-javadoc.jar' for docs. If you don't see the javadoc, then it means that the '-javadoc.jar' for that artifact is not pulled to local, in your case for the akka artifact. If you right click on the library, you should find an option to download javadoc under 'Maven' option. Once you download, you can see the javadoc.

like image 87
James Avatar answered Oct 14 '22 12:10

James