The third edition of "Java Precisely "provides a concise description of the Java programming language, version 8.0. It offers a quick reference for the reader who has already learned (or is learning) Java from a standard textbook and who wants to know the language in more detail. The book presents the entire Java programming language and essential parts of the class libraries: the collection classes, the input-output classes, the stream libraries and Java 8's facilities for parallel programming, and the functional interfaces used for that.
Though written informally, the book describes the language in detail and offers many examples. For clarity, most of the general rules appear on left-hand pages with the relevant examples directly opposite on the right-hand pages. All examples are fragments of legal Java programs. The complete ready-to-run example programs are available on the book's website.
This third edition adds material about functional parallel processing of arrays; default and static methods on interfaces; a brief description of the memory model and visibility across concurrent threads; lambda expressions, method reference expressions, and the related functional interfaces; and stream processing, including parallel programming and collectors.
After paying little attention to Java for about 10 years, I twigged that it might be prudent to catch up on what's been going on in this language.
The ideal audience for this book is a programmer with experience in at least two languages--preferably one of them C-like, one of them designed with object-orientation in mind, and if those are both the same language (e.g., C++, Objective-C, or C#), then the second language should be just about anything else, so that one's mind is accustomed to thinking about programming problems abstractly, and not in the concrete syntax of a particular language.
I am such a member of its audience, and since I desired to know quickly what's been going on in Java lately (i.e., the large additions to the language in Java "5.0", formerly known as 1.5), Sestoft's approach was nearly perfect.
Brief books on modern programming languages fill a crucial niche in the literature; witness the fact that the bibles for each of C++ (Stroustrup), C# 3.0 (Hejlsberg, Torgersen, Wiltamuth, Golde), and Java (Arnold, Gosling, Holmes) each weigh in at a thousand pages to a first approximation.
Sestoft's approach, from which he deviates on a few occasions when the material or space considerations seem to demand it, is to present language features on the left-hand pages and corresponding examples on the right. This technique mostly seems to work. To make the most of the small page budget I presume he set for himself, much material is re-used. That is, to understand the classes in example 96, you will have to refer back to their definitions in example 27. There are some forward references between examples, but most are backward, thankfully.
However, I cannot give this title a higher rating because despite its brevity, it drags a bit in a way that, say, David Beazley's Python Essential Reference (the chapters before the API reference) does not.
Some of this may be due to the nature of the material. If one is reading cover to cover, Java Precisely is about 142 pages, of which a little over thirty are on generics and the standard Collections. On the other hand, this may be my own failing as, being a systems-level guy in Unix land for most of my professional career, I've never had to deal with generics much before. Back on the gripping hand, anyone with exposure to a bit of data structures and algorithms material (linked lists, binary trees, etc.) and modern scripting language features like associative arrays (AWK, Perl, Bash 4.0) or dictionaries (Python) is not going to flabbergasted by what's here. (Update: Perhaps I should have been flabbergasted--see Terran's comment on this review.) Java's generics are, syntactically, closely modeled on C++'s, which may not have been the best decision. (Having come to C++ from C, I find just about every single one of the former's syntactical innovations to have been a bad one. Objective-C seems cleaner.)
Anyway, this is a review of Peter Sestoft's Java book, not Java itself. Nevertheless, the burden is on the author to make the material compelling, and in that endeavor I feel he succeeded most, but not all, of the time.
Whom is it for? I don't know! For beginners, it's going to be hard to understand (it doesn't necessarily explain concepts before introducing them). For intermediate and advanced coders, it's going to contain little new information (if at all). For me, an advanced beginner / intermediate, it was seldom useful and quite often confusing. Even though it's short, the book is a colossal drag. The author's way of naming classes and members makes it even worse. It turns out, "sf", "vf" is not exactly readable! I picked it because it was recommended in Effective Java, a book that's a cut above on all counts. Read it instead if you're an intermediate like me. If you're a beginner, try Head First Java
P.S.: For those interested, I read the 2002 edition so it was quite outdated too
If you are in a hurry, know how to program, and need to learn Java, this is great. It's the shortest book I found, and I felt much more comfortable after reading it. I found this through a recommendation in Effective Java.
Pros: - It's really short. - Great title. - Doesn't try to convince you that object-oriented programming is the cool new thing. - Gets pretty precise about why certain things are the way they are.
Concise reference to Java 8.0 with great coverage of newly introduced functional features.
This is the kind of reference full of examples one would want on their side when working on a project with a new/unfamiliar language. Almost comprehensively covers Java 8 features and library with clear illustrative sample code directly opposite on right-hand pages.