Eclipse not showing javadocs
Are you sure your eclipse works with a JDK and not a JRE? Go look in Project>Properties>Java Build Path
in the tab libraries
and see if you have linked a JDK or JRE.
For instance here, a JDK is used:
If you only have JRE's installed, you need to install a JDK first (find it here), then in Eclipse go to Windows>Preferences>Java>Installed JREs
and add your JDK there. Then you can add it as a library in your project settings (in the screenshot above)...
Naveen
A stupid but enthusiastic programmer ,who analyses everything too deeply.
Updated on July 09, 2022Comments
-
Naveen almost 2 years
I have JDK 7 and eclipse JUNO installed on my windows 7 system .Both of them are working fine and eclipse is very well compiling my Java apps and running them as well .
But when I roll-over my cursor on syntax,then it is not showing its description.It says :
This element has no attached source and the Javadoc could not be found in the attached Javadoc.
for every element. I could not find anything useful on the google and also there is no similar post on StackOverflow.
What is the problem?
-
Naveen over 11 years:Yes ,i said that applications are running well from eclipse. There is only
JRE System Library
. -
brimborium over 11 yearsWell they also run well if you have linked a JRE, but the Javadocs will not show up in that case IMO...
-
Naveen over 11 years:How can I link the JDK,then ?
-
brimborium over 11 yearsYou need to install a JDK first (find it here), then in Eclipse go to
Windows>Preferences>Java>Installed JREs
and add your JDK there. Then you can add it as a library in your project settings (in the screenshot above)... -
Naveen over 11 years:Thanx a lot , the JDk was already installed but eclipse was using the default jre.,not the JDK.
-
brimborium over 11 yearsIt tends to do that, yes... ;) Glad I could help.
-
Abel Morelos about 10 yearsI don't get why using a JDK solves the problem, but it solves it. Thank you.
-
brimborium about 10 years@AbelMorelos The normal JRE contains the Java Runtime with focus on being as fast, efficient and as small as possible, so standard users can conveniently download and use it to run Java programs. The JDK (Java Developer Kit) is directed towards the developer. It still got everything the JRE got, but has additionally the Javadoc (and several other things) included. Hope that answers your question. ;)