Home > Store > Programming > Java

larger cover

Add To My Wish List

Sams Teach Yourself Java 2 in 21 Days, 3rd Edition

  • By Laura Lemay, Rogers Cadenhead
  • Published Aug 15, 2002 by Sams. Part of the Sams Teach Yourself series.
    • Copyright 2003
    • Dimensions: 7-3/8" x 9-1/8"
    • Pages: 736
    • Edition: 3rd
    • Book
    • ISBN-10: 0-672-32370-2
    • ISBN-13: 978-0-672-32370-6
    • eBook (Adobe DRM)
    • ISBN-10: 0-7686-6020-3
    • ISBN-13: 978-0-7686-6020-3

Register your product to gain access to bonus material or receive a coupon.

  • Description
  • Reviews
  • Sample Content

Product Author Bios

Sams Teach Yourself Java 2 in 21 Days, Third EditionAuthor Bio

Rogers Cadenhead is the author of 12 books on Internet-related topics, including Sams Teach Yourself Java 2 in 24 Hours and Sams Teach Yourself Microsoft FrontPage 2002 in 24 Hours, but not Teach Yourself to Tell Time in 10 Minutes. Cadenhead is also a Web application developer and the publisher of sites that receive more than 7 million visits a year. He maintains this book's official World Wide Web site at http://www.java21days.com.

Laura Lemay is a technical writer and author. After spending six years writing software documentation for various computer companies in Silicon Valley, she decided that writing books would be much more fun. In her spare time, she collects computers, e-mail addresses, interesting hair colors, and non-running motorcycles. She is also the perpetrator of Sams Teach Yourself Web Publishing with HTML in a Week and Sams Teach Yourself Perl in 21 Days.

Sams Teach Yourself Java in 21 Days continues to be one of the most popular, best-selling Java tutorials on the market. Written by two expert technical writers, it has been acclaimed for its clear and personable writing, for its extensive use of examples, and for its logical and complete organization.

This new edition of the book maintains and improves upon all these qualities, while updating, revising, and reorganizing the material to cover the latest developments in Java and to expand the book¿s coverage of core Java programming topics.

Sun¿s new version of Java 2 Standard Edition¿SDK version 1.4¿is expected to be released by the end of 2001. According to Sun, version 1.4 builds upon Java¿s cross-platform support and security model with new features and functionality, enhanced performance and scalability, and improved reliability and serviceability.

Customer Reviews

87 of 89 people found the following review helpful
4.0 out of 5 stars A well-organised tutorial to get you up to speed in Java, February 18, 2000
By 
Rohan Parkes (St. Kilda, Vic Australia) - See all my reviews
(REAL NAME)   
I found most of the content in the negative reviews here bewildering. To take some examples:

"The code doesn't compile" - yes it does.

"They teach you deprecated code" - yes they do. This is because if you want to write applets, you have to use deprecated code. This is reiterated frequently throughout the applet section. They also teach you Java 2 code.

"They don't explain the examples" - yes they do, often giving line-by-line explanations. There are a couple of early examples that use yet-to-be-explained code, but they tell you this (it would be impossible to write functioning code with all you learned in day 1).

"They don't build on a foundation" - yes they do. The class concept is clearly explained, then the syntax, data types, then you move onto applet writing.

I suspect most of the negative contributors here are merely venting their frustration.

My only problem with this type of book is that it is unrealistically... Read more

Help other customers find the most helpful reviews 
Was this review helpful to you? Yes No


40 of 41 people found the following review helpful
4.0 out of 5 stars Good for beginners, something for experts, October 15, 2000
By 
Charles Ashbacher (Marion, Iowa United States) - See all my reviews
(TOP 500 REVIEWER)    (VINE VOICE)    (HALL OF FAME REVIEWER)   
An excellent criteria to apply to any book designed to teach a topic is that experienced teachers can find something to use in future lessons. Since I have taught Java for over three years and am currently teaching three sections using the JDK 1.3, I can humbly consider myself experienced in the language. There are two examples in the book that gave me the ideas for additional lessons that I have incorporated into my current classes.
However, that does not mean that the material is too advanced for beginners. On the contrary, the initial position and the movement is ideal for someone just learning the language. Some of the material that is new and improved in the JDK 1.3 is examined, although not in detail.
If you are in need of a book that will give you a quick overview of a language that you are unfamiliar with, then this book is a good choice if the language is Java. The examples are good, current and expressed in a form that is easy to understand.
Help other customers find the most helpful reviews 
Was this review helpful to you? Yes No


18 of 18 people found the following review helpful
3.0 out of 5 stars Good for someone who understands the basics of programming, December 16, 1999
By 
Steve Selleny (King of Prussia, PA) - See all my reviews
As long as you understand Object-Oriented Programming basics, this is a good place to start for learning Java. Good as a primer before you get into a book that covers Java more deeply. Of course, to really learn any language you need about 8 books on it, so don't be surprised if there's some things this book doesn't cover. It teaches you the basics of class structures, etc. and spends a lot of time on applets. I'd say that if you wanted to learn to write applications in Java 2, this is not the book for you. It mentions nothing-to-little about the implementation of data structures in Java (i.e. stacks, trees) and reading from / writing to files. Also, it assumes knowledge of SQL for the later, advanced chapters.
Help other customers find the most helpful reviews 
Was this review helpful to you? Yes No


Share your thoughts with other customers:
 See all 89 customer reviews...

Online Sample Chapters

Working with Objects

Working with Objects

Table of Contents

(NOTE: Each chapter concludes with a Summary, Q&A, Quiz and Exercises.)

Introduction.

WEEK 1. THE JAVA LANGUAGE.

Day 1. Getting Started with Java.

The Java Language. Object-Oriented Programming. Objects and Classes. Attributes and Behavior. Organizing Classes and Class Behavior.

Day 2. The ABCs of Programming.

Statements and Expressions. Variables and Data Types. Comments. Literals. Expressions and Operators. String Arithmetic.

Day 3. Working with Objects.

Creating New Objects. Accessing and Setting Class and Instance Variables. Calling Methods. References to Objects. Casting and Converting Objects and Primitive Types. Comparing Object Values and Classes.

Day 4. Lists, Logic, and Loops.

Arrays. Block Statements. if Conditionals. switch Conditionals. for Loops. while and do Loops. Breaking Out of Loops.

Day 5. Creating Classes and Methods.

Defining Classes. Creating Instance and Class Variables. Creating Methods. Creating Java Applications. Java Applications and Command-Line Arguments. Creating Methods with the Same Name, Different Arguments. Constructor Methods. Overriding Methods. Finalizer Methods.

Day 6. Packages, Interfaces, and Other Class Features.

Modifiers. Static Variables and Methods. Final Classes, Methods, and Variables. Abstract Classes and Methods. Packages. Using Packages. Creating Your Own Packages. Interfaces. Creating and Extending Interfaces. Inner Classes.

Day 7. Threads and Exceptions.

Exceptions. Managing Exceptions. Declaring Methods that Might Throw Exceptions. Creating and Throwing Your Own Exceptions. When to and When Not to Use Exceptions. Assertions. Threads.

WEEK 2. THE JAVA CLASS LIBRARY.

Day 8. Data Structures and Strings.

Data Structures. Java Data Structures.

Day 9. Working with Swing.

Creating an Application. Working with Components.

Day 10. Building a Swing Interface.

Swing Features.

Day 11. Arranging Components on a User Interface.

Basic Interface Layout. Mixing Layout Managers. Card Layout. Grid Bag Layout. Cell Padding and Insets.

Day 12. Responding to User Input.

Event Listeners. Working with Methods.

Day 13. Color, Fonts, and Graphics.

The Graphics2D Class. Color. Drawing Lines and Polygons.

Day 14. Writing Java Applets.

How Applets and Applications Are Different. Applet Security Restrictions. Creating Applets. Including an Applet on a Web Page. Java Archives. Passing Parameters to Applets.

WEEK 3. JAVA PROGRAMMING.

Day 15. Working with Input and Output.

Introduction to Streams. Byte Streams. Filtering a Stream. Character Streams. Files and Filename Filters.

Day 16. Serializing and Examining Objects.

Object Serialization. Inspecting Classes and Methods with Reflection. Remote Method Invocation.

Day 17. Communicating Across the Internet.

Networking in Java. The java.nio Package.

Day 18. JavaSound.

Retrieving and Using Sounds. JavaSound. MIDI Files.

Day 19. Creating and Using JavaBeans.

Reusable Software Components. Development Tools. Working with JavaBeans.

Day 20. Reading and Writing Data Using JDBC and XML.

Java Database Connectivity. Using XML. Processing XML with Java.

Day 21. Writing Java Servlets and JavaServer Pages.

Using Web Servlets. JavaServer Pages.

APPENDICES.

Appendix A. Choosing Java.

Java's Past, Present, and Future. Why Choose Java. Summary.

Appendix B. Using the Java 2 Software Development Kit.

Choosing a Java Development Tool. Configuring the Software Development Kit. Using a Text Editor. Creating a Sample Program.

Appendix C. Programming with the Java 2 Software Development Kit.

An Overview of the SDK. The java Interpreter. The javac Compiler. The appletviewer Browser. The javadoc Documentation Tool. The jar Java File Archival Tool. The jdb Debugger. Using System Properties. Summary. Q&A.

Appendix D. Using Sun ONE Studio.

Choosing a Java Development Tool. Configuring Sun ONE Studio. Creating a Sample Program.

Appendix E. Where to Go from Here: Java Resources.

Other Books to Consider. Sun's Official Java Site. Other Java Web Sites. Java Newsgroups. Job Opportunities.

Appendix F. This Book's Web Site.

Index

 

Book

This product currently is not for sale.

Buy

eBook (Adobe DRM)  $31.99  $25.59

About Adobe DRM eBooks

Information This eBook requires the free Adobe® Digital Editions software.

Before downloading this DRM-encrypted PDF, be sure to:


  • Install the free Adobe Digital Editions software on your machine. Adobe Digital Editions only works on Macintosh and Windows, and requires the Adobe Flash Player. Please see the official system requirements.
  • Authorize your copy of Adobe Digital Editions using your Adobe ID. If you don't already have an Adobe ID, you can create one here.
Purchase Reward: One Month Free Subscription
By completing any purchase on InformIT, you become eligible for an unlimited access one-month subscription to Safari Books Online.

Get access to thousands of books and training videos about technology, professional development and digital media from more than 40 leading publishers, including Addison-Wesley, Prentice Hall, Cisco Press, IBM Press, O'Reilly Media, Wrox, Apress, and many more. If you continue your subscription after your 30-day trial, you can receive 30% off a monthly subscription to the Safari Library for up to 12 months. That's a total savings of $199.