Download the javadocs zip file from java website (link for Java 7 docs
Here).
Now in ur eclipse go to the Prefernces

and choose Installed JREs

Now if u have multiple JREs installed choose the one which you use and click Edit
.
Note that the JRE for which the checkbox is checked is the one which is
default, u can over ride the default for a specific project.

Expand the lib\rt.jar
as shown below.And select the Javadoc location
property, click on Javadoc Location
button

NOTE :If u have chosen a JDK (as shown above) then there will automatically be a
source attachment.(And u probably wont need a javadoc-api explicitly).But in case of a JRE the source will not be available unless specified manually.(See next image.).In Either case u can attach a javadoc offline.

Now in the javadoc window select Javadoc in archive
radio button and click on Browse...
, select the javadoc zip file downloaded earlier

Click OK
or Finish
to close all the open windows (javadoc window, Edit JRE window, and Preferences window)
That's it!! Now u can use the javadoc, Enable the javadoc view in Window > Show View > Javadoc.

Just double click on any class in ur java src file editor and u will see the javadoc for it in the javadoc window as well as in a tool tip.

Hope its solved ur problem. Let me know if u have any issues.