Skip Navigation | ANU Home | Search ANU | Search FEIT | Feedback
The Australian National University
Faculty of Engineering and Information Technology (FEIT)
Printer Friendly Version of this Document

COMP 2100 and COMP2500
Software Construction
Software Construction for Software Engineers

About Java

We will be using Java 1.5 (otherwise known as Java 5) in COMP2100/2500 this semester. This version of the language has some distinct advantages over earlier versions, that you may have learnt before 2006:

  • a convenient way to read input from the console using the Scanner class (at last);

  • automatic conversion from int to Integer etc. and back again; and

  • generic classes, that greatly improve type-safety in data structures.

For a reminder and access to tutorial materials on many aspects of introductory, intermediate and advanced Java, see The (Sun) Java Tutorials.

For more information about Java 1.5, see the article Programming with the New Language Features in J2SE 5.0.

Java 1.5 is available for Windows, Solaris and Linux from Sun, and for Macintosh OS X 10.4 "Tiger" from Apple. Java 1.5 is what is installed as javac on the ANU Unix laboratory environment.
[To check this assertion: execute the command javac -version]

Java documentation

Top of the Tree

The first place you might think to look is the Sun Java website. This has lots of information, some of it very helpful, some of it incomprehensible, some simply irrelevant. You might want to skip straight to their Java 1.5 page.

Class Libraries

The place you will most often look, almost every time you sit down to program in Java, is the API Documentation. This gives the full specification (and some helpful description) of the entire Java standard libraries, including the GUI (graphical user interface) libraries. Take the time to get to know this documentation, because you will use it all the time.

In an IDE

If you use an integrated development environment (IDE) such as eclipse you can get direct access to the library documentation and its implementation.

Warning- the cost of accessing information

Downloading web pages from the Sun Java site costs the university money and hits your download quota, so if you are working in the labs you should use our local mirror copy of the Java API docs instead.

Precise language description

The precise definition of the Java language and how it should work is contained in the Java Language Specification third edition, but my guess is that you're unlikely to find anything useful in this extremely technical document.

One of the online resources is a concise tutorial description of the language by Sesoft: his program examples for Java 5 are online, but the online descriptive text is for an earlier version of Java.

Java programming environment

One of the objectives of this course is for you to become familiar with the standard basic programming environment, consisting of a text editor (Emacs) and a command line.

But we will also be experimenting with Integrated Development Environments. The leading example of an IDE for the university environment is Eclipse, a large, open-source, extensible integrated development environment.

Other Java resources

There are some useful links to Java tutorials, books, and other useful information like installation guides available from the COMP1100 Java Page.

For those of you getting back into programming and changing languages from Eiffel to Java, Patrick Harrison wrote Eiffel to Java for COMP1110 students, which you may find useful. (It doesn't look very good on my screen, but it prints just fine.)


About Emacs

In response to a query about Emacs on Windows, I present some links here. Do read the Emacs for Windows README. Then download djtarnt.exe, emacs-21.3-fullbin-i386.tar.gz, and eiffel.el. Install the latter in the site-lisp directory and follow its instructions in the INSTALLATION section.

Page updated: 13 Feb 2007 cwj