By Bruce Eckel
The releases of the Java JDK are numbered 1.0, 1.1, 1.2, 1.3, and for this book, 1.4. Although these version numbers are still in the “ones,” the standard way to refer to any version of the language that is JDK 1.2 or greater is to call it “Java 2.” This indicates the very significant changes between “old Java”—which had many warts that I complained about in the first edition of this book—and this more modern and improved version of the language, which has far fewer warts and many additions and nice designs.
This book is written for Java 2, in particular JDK 1.4 (much of the code will not compile with earlier versions, and the build system will complain and stop if you try). I have the great luxury of getting rid of all the old stuff and writing to only the new, improved language, because the old information still exists in the earlier editions, on the Web, and on the CD ROM. Also, because anyone can freely download the JDK from java.sun.com, it means that by writing to JDK 1.4, I’m not imposing a financial hardship on anyone by forcing them to upgrade.
Previous versions of Java were slow in coming out for Linux (see www.Linux.org), but that seems to have been fixed, and new versions are released for Linux at the same time as for other platforms—now even the Macintosh is starting to keep up with more recent versions of Java. Linux is a very important development in conjunction with Java, because it is quickly becoming the most important server platform out there—fast, reliable, robust, secure, well-maintained, and free, it’s a true revolution in the history of computing (I don’t think we’ve ever seen all of those features in any tool before). And Java has found a very important niche in server-side programming in the form of Servlets and JavaServer Pages (JSPs), technologies that are huge improvements over the traditional Common Gateway Interface (CGI) programming (these and related topics are covered in Thinking in Enterprise Java).