Is there an integration of any other off line way to get the Java API docs?
3 Answers
If you have no internet connection on your development machine, or if you want to stop the Web traffic for accessing the documentation, you can store the documentation on your local hard drive.
- Start your favorite Web browser and navigate to http://www.oracle.com/technetwork/java/javase/downloads/index.html#docs
- Find your desired documentation, accept the license agreement, and then click the link displayed under the
Downloadheader. - In Eclipse, open the
Windowmenu, then selectPreferences. - In the search bar, type
jre, and then clickInstalled JREs. - Select the one named
java, or another term likejre1.8.0_181.- Its type must be
Standard VM.
- Its type must be
- Click the
Editbutton. - In the
JRE system librariessection, select the library ending withrt.jar, and click theJavadoc Location...button. - Mark the
Javadoc in archiveradio button. - In the
Archive pathfield, enter orBrowsefor your full documentation path (e.g./home/docs/jdk-8u181-doc.zip). - In the
Path within archivefield, enter orBrowsefor the location of theapi/index.htmlfile (e.g.docs/api). - Click the
Validatebutton to ensure everything is set correctly. - Click the
OKbutton, then theFinishbutton, and finally theApply & Closebutton. Your documentation is now linked to the file you specified.
2 Comments
This worked for me (Java 8):
Go to your JDK installation. (
C:\Program Files\Java\jdk1.8.0_66for me).Unzip the
src.zipfile (becomesC:\Program Files\Java\jdk1.8.0_66\src\for me).In the Eclipse editor window:
CTRL + Clickon ajava.langlibrary class. (something likeString).Eclipse will complain
Source not foundand tell you that you don't have the source.Click
Attach source->External Location->External Folder.Find your source folder (
C:\Program Files\Java\jdk1.8.0_66\src\for me).Click
OK->OK.Enjoy.