Eclipse Oxygen.2 (4.7.2) fails to load standard javadoc when I select my JRE 9 install as default JRE.
Is that a bug?
When I switch back to JRE 8 it works.
EDIT
So, I was a bit short on that one, let me explain. When I select a JRE for Eclipse (Preferences > Java > Installed JREs), should it be a JRE9, a JDK9, a JRE8 or a JDK8 location, when I Edit
it, I can see in the jrt-fs.jar (9) or in each separated jar including rt.jar (8) a Source attachment
location (empty for JRE which is normal) and Javadoc location
(official HTTP URL).
That's why I expect the Javadoc to display even with a JRE.
Now when I hover over a standard Java class, say java.io.IOException
or java.lang.String
for example:
http://download.java.net/java/jdk9/docs/api/java/io/IOException.html
which is the URL in the Javadoc Location of JRE9 & JDK9java.io.InputStream
, I get an Eclipse error: Exception:org.eclipse.jdt.core.JavaModelException: I/O exception
which is Caused by: java.io.IOException: null
, followed by a Java Model Exception: Java Model Status [C:\\Program Files\\Java\\jdk-9.0.4\\lib\\jrt-fs.jar\\java.base is not on its project's build path]
attached Javadoc in browser
( docs.oracle.com/javase/8/...
)So there are at least three problems:
Eclipse doesn't pull the tooltips from the javadoc location
, so where does it pull it from?
[jdk9_path]/lib/src.zip
as Source Location
in my JRE9 and it works.jrt-fs.jar\\java.base
, which does not exist?
http://download.java.net/java/jdk9/docs/api/
)?JREs are the bare runtimes, they do not contain the compiler, packaging tools, sources, or documentation . The easiest solution is often to use a JDK instead.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.