Java has quickly become one of the most important languages in programming, particularly for professional and enterprise-level projects. From its infancy as a language primarily used for web applets to its maturity through servlets, Enterprise JavaBeans, and database access, Java has become a complex and robust tool for today's developer.
Hardcore Java takes this language and breaks it apart, piece by piece, revealing the important secrets and tricks that will take you from a junior-level programmer to a seasoned and expert developer. You'll fly through the fundamentals and quickly find yourself learning about advanced memory management techniques, optimization and bytecode-level enhancements, and the techniques required to build lightning-fast GUIs. Throughout the book, you'll also master the art of writing and maintaining bulletproof and error-proof code, all while grasping the intricacies of the Java language.
Hardcore Java covers:
Use of the final keyword to optimize and protect your Java classes.
Complete and thorough coverage of all types of nested classes, including how to optimize anonymous and inner classes.
Detailed discussion of immutable objects, including unique tips on when to use them (and when not to).
Elimination of bugs through exception-handling management.
In-depth studies of constants, including their impact on the Java memory model.
The most thorough discussion of reflection in print, moving far beyond other books' "Hello World" coverage.
Construction and use of dynamic proxies, in both Java Standard and Enterprise editions.
Expansive coverage of weak references, including usage patterns and their role in garbage collection and memory management.
Hardcore Java is an invaluable addition to every programmer's library, and even the most advanced developers will find themselves moving beyond their own conceptions into truly advanced applications of the language. Thousands of lines of code, heavily commented and easily runnable, illustrate each concept in the book.
Robert Simmons, Jr. started programming when floppy disks were really floppy and 64 kilobytes of RAM was considered state of the art. From his early days of programming BASIC and Logo on an Apple IIe, he advanced through Pascal and C to arrive in the object oriented realm of C++. When Java first came out, he knew that the infant language would become a serious player amongst corporations; Robert learned Java and began using it as his primary language for programming in 1997. Although Robert is American, he lives and works as a Senior Software Architect in Germany.
Our look is the result of reader comments, our own experimentation, and feedback from distribution channels. Distinctive covers complement our distinctive approach to technical topics, breathing personality and life into potentially dry subjects. The animal on the cover of Hardcore Java is a lion. The lion (Panthera leo) is the largest of the African carnivores. Males, distinguished by their tawny manes, can weigh up to 500 pounds; the smaller, maneless females can weigh up to 300 pounds. Both sexes are powerfully built. Their muscular bodies can take down such large prey as buffalo, giraffe, and young elephants, but they usually hunt medium- to large-sized herd animals, such as antelopes and gazelles.
The regal designation "king of the jungle" is a misnomer. Lions tend to live on the open plains throughout sub-Saharan Africa. Nor are they the ferocious, man-eating beasts portrayed in old stories and movies. Though lions have been known to attack humans when provoked, their lifestyle is surprisingly laid-back. They love to lie around and snooze in the sun, and are active for only two to four hours a day. They hunt in groups, usually at night. A pride consists of 12 females that are closely related and up to 6 males.
While their day-to-day life may be easygoing, the mating rituals of lions are often savage and deadly. Males mate with females of their pride. The toughest males can take over a pride by expelling other males in bloody, often fatal, fights. These males are then expelled by younger, stronger males within 1 to 10 years. New males not only kill off their rivals, but they also kill the pride's cubs to ensure that the females will once again be ready to breed, thereby guaranteeing that their genes will be passed on.
The lion's most prominent trait, its bloodcurdling roar, is used by both males and females during mating and to keep other predators at a distance. A roar will often begin with a low rumble and slowly build to a deafening crescendo before subsiding. Matt Hutchinson was the production editor and copyeditor for Hardcore Java. Mary Brady proofread the book. Sarah Sherman, Mary Brady, and Claire Cloutier provided quality control. John Bickelhaupt wrote the index.
Ellie Volckhausen designed the cover of this book, based on a series design by Edie Freedman. The cover image is a 19th-century engraving from the Dover Pictorial Archive. Emma Colby produced the cover layout with QuarkXPress 4.1 using Adobe's ITC Garamond font.
Melanie Wang designed the interior layout, based on a series design by David Futato. This book was converted by Julie Hawks to FrameMaker 5.5.6 with a format conversion tool created by Erik Ray, Jason McIntosh, Neil Walls, and Mike Sierra that uses Perl and XMLtechnologies. The text font is Linotype Birka; the heading font is Adobe Myriad Condensed; and the code font is LucasFont's TheSans Mono Condensed. The illustrations that appear in the book were produced by Robert Romano and Jessamyn Read using Macromedia FreeHand 9 and Adobe Photoshop 6. The tip and warning icons were drawn by Christopher Bing. This colophon was written by Matt Hutchinson and Genevieve d'Entremont.
Not bad, good for introductions to advanced language features
By Bart Schouten
Comments about oreilly Hardcore Java:
This is not an extremely good book, but it is not bad either. The preface is slightly misleading; it is not as hardcore as it sounds. You are warned that you need to be familiar with technologies such as JavaBeans, and at first I thought this book would be too advanced for me, but as I read on, it proved quite accessible for anybody familiar with the basics of the Java languange.
I do not consider the author an expert in any of the topics he discusses in the book. See him as an experienced programmer that shares the tricks of the trade that he has made his own.
Nevertheless, the topics he addresses are covered thoroughly and many potential pitfalls are shown and explained.
The author proposes to use final variables whenever you can to save you some debugging headaches. I thought this to be a bit of an annoyance, but after I realized that it could also be used as a way of signaling to the users of a method that a parameter will not be changed by the method, I decided to adopt it for method declarations (although it is no guarantee that the parameter will indeed not be changed).
Though this book is outdated at this time, it still provides a good (and thorough) introduction to topics such as assertions, reflection, weak references, exceptions, contraints, generics, and other features of Java 1.5, that every programmer should be familiar with. If you want to learn more about Java than the basics you already know, or if your Java knowledge is a bit dated and you need to catch up with 1.5 (not to mention 1.6), this is a book for you. Much better than scourging the net in search of features, articles and howto's.
A bit stupid was that the author covered in great detail a technique known as Constant Objects for use as option constants, without mentioning the fact that later in the book a new language feature called enumerations would be introduced, that makes the whole constant objects idea pretty much obsolete.
I felt totally let down (ok thats diplomatic.. I felt totally cheated is the correct statement). The title and preface talks highly about this book. Nothing I found in this book which is "hardcore". They are pretty basic java. Also I found cases where this book actually suggests tricks and techniques which are pure bad practices. I would advice against reading this book to anybody who is contemplating to do so. I would also suggest safari to remove this book from their catalog, since the title and the preface in this book is highly misleading. A 1000 times better book which I would recommend to every Java developer is Effective Java by Joshua Bloch.
Before I started reading the book I had high expectations: wow, a book from O'Reilly called 'Hardcode Java', that must be good! Unfortunately, the book was a big disappointment for me. It has nothing to do with Hardcore Java - buy Java Puzzlers or Effective Java by Josh Bloch if you want Hardcore Java from a real expert.
The book contains multiple code sample errors, but which book doesn't... What really disturbed me are all these advices the author tries to give, although most of them I can't agree with at all and some of them I would even call 'bad practices' (many of his advices are also in contradiction with Josh Bloch's arguments). The repeated complaints about why Sun made certain decisions is also annoying and this attitude seems quite arrogant to me.
I'm sorry to say but, in my opinion, if you're an advanced Java programmer, this book won't take you to the next level nor will it provide you new insights :-( But read and decide yourself.
The author felt the need to 'rebalance' the reviews. I feel that need also.
Read the errata before buying this book. I read a review on Amazon (check those reviews before purchasing) where the reviewer said that with some scissors and paste and a print out of the errata, this book is good. I find that rather amusing.
Other than that, there's nothing in this book that you can't find out by reading articles on the web.
This is one of the most consistently panned books. Most of the praise is lukewarm.
If you want a good book, get Josh Bloch's "Effective Java".
After reading this book, the first thing that came to mind was that the book was probably titled incorrectly. In my opinion, there is nothing "hardcore" in this book at all. Instead, it should be called Smart Java, because it contains many smart practices to follow in your Java programming. These are practices that every Java programmer needs to know in order to write rock-solid Java programs. Therefore, I recommend this book to any Java programmer.
Many of the chapters focus on coding techniques that can be used to prevent run-time logic errors and instead letting the compiler catch your mistakes for you. These techniques can save a tremendous amount of time because it is easier to track down errors at compile time rather than hunting down the bug when the program runs incorrectly. These techniques reminded me of similar techniques I used to follow as a C++ programmer that sort of got lost on me when I started programming in Java. Some such practices include using keywords such as assert and final. There is also a good chapter on techniques for declaring constants to make your code type-safe.
There are a few chapters in the book that I wasn't particularly interested in learning about. For instance, the chapter called "Data Modeling" seemed to not quite fit with the rest of the book. It involved more design practices than coding practices. However, I'm sure these chapters may be useful to some programmers out there.
The last chapter of the book discusses the new JDK 1.5 and the new features that it will offer. The author does a good job of explaining these features, and how the next version of the JDK will make Java an even better language than it already is. Some of the new features even make some of his earlier suggestions in the book outdated. This chapter provided a good end to this book because it will allow the programmer to make full use of all the wonderful new features of the new JDK once it is finally released.
Overall, the book was quite good. There were a few chapters of the book that didn't quite seem to fit the theme of the book, but they still provided intelligent insights into Java programming. There were spelling errors sprinkled throughout, but nothing that really caused misinterpretation of the author's points. As I said before, I would highly recommend that all Java programmers read this book! Even the most hardcore of programmers may learn a thing or two!
I had high hopes purchasing this book, as its title combined with its chapter list promised a good read. I was pretty disappointed at the end, especially since the last chapter is by far the worst.
"The Final Story" chapter made some good points, but those could have been made in much less than thirty pages. The "Immutable Types" chapter should be skipped, as Josh Bloch describes the issue much better in "Effective Java". The "Data Modeling" chapter would make an excellent magazine article (or series even), but is completely out of place in this book.
But there are some good bits, too: the "Nested Classes", "Practical Reflection", "Proxies" and "References in Four Flavors" bring light to poorly understood topics.
The "Tiger: JDK 1.5" chapter is a disaster, because the author's arrogant attitude across strongly as he makes several false statements. It's puzzling, for example, how a reflection guru claims that all of the generic type information is stripped during compilation -- didn't he notice all of the new classes and methods in the java.lang.reflect package for 1.5? Didn't he realize that the compiler needed type signatures for the Collections classes his samples extended?
Then there's the whining, such as his claim that Sun rejected all proposals to implement runtime safety. This complaint ignores all of the other people on the JSR-14 expert group who participated in those decisions, including one of the original authors of the gjc compiler. The Java community has been reviewing the generics proposal since May, 1999, and perhaps the author could have better spent his time participating then.
So take this book with a big grain of salt (perhaps on the rim of a marguerita glass): it makes several good points, but you have to filter out the author's biases much more than other O'Reilly books.
Informative but certainly not strictly for the hardcore. If you wish to know java in and out, don't be afraid to give this book a shot. I've gone through it twice now to brush up, and a few of my friends have borrowed it, only to wander off and buy their own when I threatened them with dire consequences if it wasn't returned. Good job.
PS: Don't let the jerks get you down, anonymity doesn't always lead to good people doing bad things, in forums or otherwise.