Java 5 and Eclipse 3.1M4
CIT 594, Spring 2005

Getting Java 5 for Windows:

  1. Go to

  2. Under J2SE 5.0 JDK, click the Download JDK link and follow instructions. You should get an installer named jdk-1_5_0-windows-i586-1.exe.

  3. Run the installer.

  4. On this same page as #1, under J2SE Documentation, download and unzip the documentation.

  5. In your browser, set a bookmark to either docs/index.html (Sun's recommendation) or to docs/api/index.html (my recommendation).

Getting Eclipse for Windows:

Note: Eclipse 3.1M1 is the first version to support any Java 5 features; the current build, 3.1M4, supports most of the Java 5 features. Some experimentation may be needed to find out what to avoid. Eclipse 3.1 does not appear to be as stable as 3.0 (I've had it crash), but we need 3.1 so we can use Java generics.

  1. Go to and download the Windows 98/ME/2000/XP version, using either the http link or the ftp link.

  2. Put the zip file someplace convenient, and unzip it. If you simply replace your old Eclipse files with new ones, your aliases should continue to work. You can discard your old version of Eclipse, but be careful not to discard your workspace, which contains the programs you wrote!

  3. Try to remember where you put your Java executables and doc files.

  4. In Eclipse, go to Project > Properties > Java Build Path > Libraries, click on the old JRE, and remove it. Then click on Add Library... > JRE System Library > Installed JREs, click Edit... , select the old JRE and Edit... it, then:
    1. Change the JRE name from j2re1.4.2_06 (or similar) to jre1.5.0.
    2. Browse... the JRE home directory from C:\Program Files\Java\j2re1.4.2_06 (or similar) to wherever you put the JRE; mine is at C:\Program Files\Java\jre1.5.0.
    3. Browse... the Javadoc URL from whatever it is to wherever you saved them; probably something like file:/C:/Program Files/Java/docs/api/.

  5. In Eclipse, go to Window > Preferences > Java > Compiler > Compliance and Classfiles > Compiler compliance level and change all settings to 5.0.

  6. Try out a simple Java 5 program, such as this one:
    public class JustTestingJava5 {
        enum Season { SUMMER, FALL, WINTER, SPRING }
        public static void main(String[] args) {
            for (Season s : Season.values()) {

Getting Java 5 for Macintosh:

Apple will bundle Java 5 with its next operating system release ("Tiger," Mac OS X 10.4), but has not yet specified a release date. There is some reason to believe that it will become available during the Macworld Conference & Expo, January 10-14, but other reasons to believe that it will be available March 24.

An expensive alternative is to go to Apple Developer Connection and pay $500 to become an "ADC Select Member," which will allow you to get the "Tiger Early Start Kit for Developers." I do not recommend this option unless you have other reasons of your own to join ADC.

Getting Eclipse for Macintosh:

Since Java 5 isn't yet available, it's not clear that there's any point to getting a newer version of Eclipse. However, if you want to, you can go to any of the sites as described above and download eclipse-SDK-3.1M4-macosx-carbon.tar.gz. Unpack these files (typically this will happen automatically) and put them in some convenient location.

Eclipse can be set to compile Java 5 code, but since you don't have Java 5, there isn't much point to doing so. Go to Window > Properties > Java Compiler > Configure Workspace Settings... and set the three pulldowns to 1.4.