tags:

views:

210

answers:

4

The network between our company and Sun's javadocs seems to be down. Where can I get a copy of the javadocs for a given package, so that I can keep my own stash to handle network outages in the future? Are there any mirrors for the Sun javadocs?

+2  A: 

Most surefire bet: download the source and run Javadoc over it yourself, and stick it on an internal web server.

(FWIW - I can't reach their javadocs from my internal network right now either.)

Jared
It requires a lot of memory and a long time to do that... I looked into this once and my computer at the time didn't have enough RAM (this was several years ago, though).
David Zaslavsky
Yeah. I've done it. The amount of time/memory required is relatively high, but I also recall that you can alter Javadoc output settings (not display all uses of all classes, for example) to optimize for that.
Jared
well when the site is back up you can just grab a copy and host it locally :-)
TofuBeer
Most IDE's support attaching this source JAR to the JRE library entry. This allows you to view the javadoc from inside the IDE by using code completion and other commands.
Outlaw Programmer
I'm very late to the party, but I'd like to add the suggestion to simply download the documentation (offered as a separate download), to unzip it and host that somewhere. Generating the JavaDoc from source seems to me to be very unnecessary.
Carl Smotricz
+4  A: 

For each major release there is a large doc package, e.g. here for JDK 1.6.

(I hope the link is correct, picked it out of the docs I downloaded a while ago. Can't connect to SUN either from here.)

starblue
if i could have accepted more than one answer i'd accept this one too
Jason S
+2  A: 

Down for me too (java.sun.com seems to be MIA at the moment).

Some form of the JDK docs are here: http://www.docjar.com/docs/api/java/

TofuBeer
(accepted for solving my immediate problem)
Jason S
+2  A: 

I run classfinder on a MacMini locally. It's a small webserver dedicated to serving Javadoc and related source. You just take the zipped Javadoc and (optionally) the source package, and drop them in the appropriate directory. Classfinder works out the dependencies between all the docs and presents everything as a unified set of docs.

If you have multiple versions of packages (e.g. different servlet docs) you can dynamically select what you want to display. It all works beautifully and deserves much more fame than it currently gets.

Brian Agnew
Great tip, thank you very much!
Carl Smotricz