Effective Java 2nd Edition


The Java programming language, for example, is object-oriented with singleinheritance and supports an imperative (statement-oriented) coding style withineach method. The libraries address graphic display support, networking, distrib-uted computing, and security. But how is the language best put to use in practice? There is another point. Programs, unlike spoken sentences and unlike most books and magazines, are likely to be changed over time. It��s typically not enough to produce code that operates effectively and is readily understood by other persons; one must also organize the code so that it is easy to modify. There may be ten ways to write code for some task T. Of those ten ways, seven will be awkward, inefficient, or puzzling. Of the other three, which is most likely to be similar to the code needed for the task T�� in next year��s software release?
There are numerous books from which you can learn the grammar of the Java Programming Language, including The Java™ Programming Language by Arnold, Gosling, and Holmes [Arnold05] or The Java™ Language Specification by Gosling, Joy, yours truly, and Bracha [JLS]. Likewise, there are dozens of books on the libraries and APIs associated with the Java programming language. This book addresses your third need: customary and effective usage. Joshua Bloch has spent years extending, implementing, and using the Java programming language at Sun Microsystems; he has also read a lot of other people��s code, including mine. Here he offers good advice, systematically organized, on how to structure your code so that it works well, so that other people can understand it, so that future modifications and improvements are less likely to cause headaches perhaps, even, so that your programs will be pleasant, elegant, and graceful.

No comments:

Post a Comment