Home > Store

Java Tutorial Continued, The: The Rest of the JDK

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

Java Tutorial Continued, The: The Rest of the JDK

Book

  • Sorry, this book is no longer in print.
Not for Sale

Description

  • Copyright 1999
  • Dimensions: 7-3/8" x 9-1/4"
  • Pages: 976
  • Edition: 1st
  • Book
  • ISBN-10: 0-201-48558-3
  • ISBN-13: 978-0-201-48558-5

The Java(tm) Tutorial Continued provides accurate, up-to-date coverage of features added to the original core Java platform. Written by the experts, The Java Tutorial Continued employs a hands-on, self-paced, example-driven approach. This book concentrates on JDK 1.2 APIs but also contains the information you need to use the JDK 1.1 versions of the APIs.

The tutorial books, including this book and The Java Tutorial, are the definitive programmers' guides to the core JDK. This book covers a broad spectrum of JDK features, including:

  • The Java Collections Framework
  • Internationalization
  • 2D Graphics and Sound
  • JavaBeans(tm)
  • IDL (Interface Definition Language), which adds CORBA capabilities to the Java platform
  • Database connectivity through the JDBC(tm)
  • RMI (Remote Method Invocation)
  • Security
  • JNI (Java Native Interface)
  • Reflection
  • Other topics such as JAR, the Standard Extension Mechanism, and Servlets

The accompanying CD-ROM contains all the material from both The Java Tutorial and The Java Tutorial Continued in HTML, including the source code for all of the examples. The CD-ROM also has much more, including the JDK and everything you need to start programming with JDK 1.2.

You will come away from this tutorial with an excellent conceptual understanding of the JDK, along with the practical know-how to put the Java platform to work for you.



0201485583B04062001

Sample Content

Table of Contents



Preface.


Overview of JDK Features.

Lesson 1 A Day in the Life.

Lesson 2 All Things New with JDK 1.2.

Lesson 3 Features Roadmap.



Collections.

Lesson 4 Introduction.

Lesson 5 Interfaces.

Lesson 6 Implementations.

Lesson 7 Algorithms.

Lesson 8 Custom Implementations.

Lesson 9 Interoperability.



Working with Java 2D Graphics.

Lesson 10 Overview of the Java 2D API.

Lesson 11 Displaying Graphics with Graphics2D.

Lesson 12 Manipulating and Displaying Images.

Lesson 13 Printing.



Java Sound.

Lesson 14 Playing Sounds.

Lesson 15 Java Sound Engine Integration.

Lesson 16 Common Problems (and Their Solutions).



JavaBeans: Java Platform Components.

Lesson 17 JavaBeans Concepts and Development Kit.

Lesson 18 Using the BeanBox.

Lesson 19 Writing a SimpleBean.

Lesson 20 Properties.

Lesson 21 Manipulating Events in the BeanBox.

Lesson 22 The BeanInfo Interface.

Lesson 23 Bean Customization.

Lesson 24 Bean Persistence.



JDBC Database Access.

Lesson 25 JDBC Basics.

Lesson 26 New Features in the JDBC 2.0 API.



Programming with Java IDL.

Lesson 27 Introducing Java IDL.

Lesson 28 The Hello Client-Server Example.

Lesson 29 Java IDL Summary.



Using Java RMI.

Lesson 30 An Overview of RMI Applications.

Lesson 31 Writing an RMI Server.

Lesson 32 Creating A Client Program.

Lesson 33 Compiling and Running the Example.



Servlets.

Lesson 34 Overview of Servlets.

Lesson 35 Interacting with Clients.

Lesson 36 The Life Cycle of a Servlet.

Lesson 37 Saving Client State.

Lesson 38 The servletrunner Utility.

Lesson 39 Running Servlets.



Security.

Lesson 40 Security Features Overview.

Lesson 41 Quick Tour of Controlling Applets.

Lesson 42 Quick Tour of Controlling Applications.

Lesson 43 Secure Code and File Exchanges.

Lesson 44 Tools to Sign Code and Grant Permissions.

Lesson 45 Tools for Exchanging Files.

Lesson 46 Generating and Verifying Signatures.

Lesson 47 Implementing Your Own Permission.



The Java Archive (JAR) File Format.

Lesson 48 Using JAR Files: The Basics.

Lesson 49 Signing and Verifying JAR Files.

Lesson 50 Using JAR-Related APIs Introduced in 1.2.



The Java Extension Mechanism.

Lesson 51 Creating and Using Extensions.

Lesson 52 Setting Extension Security Privileges.



Using the Java Native Interface.

Lesson 53 Overview of the JNI.

Lesson 54 Writing a Java Program with Native Methods.

Lesson 55 Integrating Java and Native Programs.

Lesson 56 Interacting with Java from the Native Side.

Lesson 57 Invoking the Java Virtual Machine.

Lesson 58 Summary of the JNI.



The Reflection API.

Lesson 59 Examining Classes.

Lesson 60 Manipulating Objects.

Lesson 61 Working with Arrays.

Lesson 62 Summary of Classes.



Reference Objects.

Lesson 63 Understanding Garbage Collection.

Lesson 64 All About Reference Objects.



Appendixes.


Appendix A: Code Examples.


Appendix B: Reference.


Index. 0201485583T04062001

Preface

As the title implies, this volume of The Java Tutorial starts where the first ended. The first book covers API present in the Java platform's first release.

This book covers API subsequently added to the Java platform.

This book is a collection of tutorials written by Java team members. Each author who contributed to this book is an authority in his or her area of the Java platform. Some authors are even the creators of the API they describe.

The content of this book is available online, along with the content of the first volume here:

http://java.sun.com/docs/books/tutorial/index.html

From the online tutorial to the first volume, and from the first volume to this one, our intent has always been to create a fun, easy-to-read, task-oriented programmer's guide with lots of practical examples to help people learn to program using the Java platform.

The hyperlinked origins of this book will be evident as you read it. For instance, underlined phrases throughout this book mimic online links. A link to material within this book is followed by the appropriate page number. A link to material outisde this book, such as to the JDK API documentation, is accompanied by a footnote that contains a URL. Other evidence of this book's online origin can be found on the first page of each trail/lesson, which provides the URL where the trail/lesson can be found in the online tutorial.

You might be wondering why we use the terms "trails" and "lessons." We know that people don't learn linearly. People learn by posing a problem, solving it, uncovering other problems, solving them, and learning information as the need arises. Our original vision for the online tutorial was to encourage and enable this type of thinking and learning. We envisioned a mountain of ski trails, where at any junction, a reader could choose the most interesting or appropriate path at that time. But we also needed some sort of structure and organization, so we created a two-tier hierarchy; trails at the top level and lessons within them. We also use a high level of linking to help you pick and choose where you go and when.

What You Need

This book documents the Java Development Kit TM (JDK) 1.2 release of the Java platform. To compile and run the examples in this book you need a development environment that is compatible with JDK 1.2. You can use a commercially available development environment or the JDK itself. We've included JDK 1.2 on the CD-ROM that accompanies this book. Or you might want to visit the Java Web side to download the latest version of the JDK:

http://java.sun.com/products/jdk/1.2/

If you are using the JDK provided by Sun Microsystems, you will need one of the following systems:

  • Microsoft Windows 95/ NT 4.0 running on Intel (or compatible) x86
  • Solaris 2.4, or 2.5 running on SPARC
  • Solaris 2.5 running on x86

If you are developing applets, you will need a browser that supports the 1.2 API, or install the Java Plug-in. The Java Plug-in ensures that your browser uses the latest Java Runtime Environment compatible with JDK 1.2. The Java Plug-in is included on the CD-ROM that accompanies this book and is also available online here:

http://java.sun.com/products/plugin/

For testing applets, you could also use a special limited browser called the Applet Viewer that ships with the JDK.

Finally, you need an editor that can save files in ASCII format with a .java extension. Also, the editor must allow you to specify both uppercase and lowercase letters in the filename.

About the Authors

Find out more about the authors who contributed to this book.

Deborah Adair, author of Working with Java 2D Graphics and Java Sound

Deborah Adair, the technical writer for the Java Media group at Sun Microsystems, specializes in designing and writing documentation for software developers and other highly technical readers. She has a degree in Scientific and Technical Communication from the University of Washington and has been writing for the computer industry for the past nine years.

Cindy Bloch, author of Servlets

Cynthia Bloch writes technical documentation at Sun Microsystems' Java Software division. She has a Master's in Information Science from the University of Pittsburgh. Since graduate school she has worked as a Senior Software Engineer at Carnegie Group Incorporated in Pittsburgh, Pennsylvania, and as a Senior Technical Trainer at Transarc Corporation in Pittsburgh, Pennsylvania.

Joshua Bloch, author of Collections

Joshua Bloch is a Senior Staff Engineer at Sun Microsystems' Java Software division, where he works as an architect in the Java Language Group. His major contributions include the Collections Framework and java.math.

In a former life, Josh was a Senior Systems Designer at Transarc Corporation in Pittsburgh, Pennsylvania, where he designed and implemented many parts of the Encina distributed transaction processing system. In the deep dark past, he held summer positions at the usual corporate research labs (Bell Labs and IBM Research).

Josh holds a Ph.D. in computer science from Carnegie-Mellon University, where he wrote a long, boring dissertation on replication, and designed and implemented the language layer of the Camelot distributed transaction processing system. He holds a B.S. in computer science from Columbia.

Mary Dageforde, author of Security

Mary Dageforde writes software documentation for various Silicon Valley computer companies, including Sun Microsystems. She has a Master's in Computer Science from Stanford University. She spent ten years working primarily on the design and implementation of the English-like customer programming language for the pioneering Xerox Star GUI environment and its successors. For the past eight years she has concentrated on documenting APIs, languages, tools, and systems.

Maydene Fisher, author of JDBC Database Access

Maydene Fisher has extensive experience as a technical writer specializing in the documentation of object-oriented programming languages. Fisher began her technical writing career on Wall Street, where she documented complex computer models, written in C++, for simulating fixed income derivatives. Before joining the JDBC team at Sun's Java Software division, she wrote documentation for ScriptX, an object-oriented multimedia scripting language, at Kaleida Labs and at Apple Computer.

Dale Green Author of Internationalization and The Reflection API

Dale Green is a staff writer with Sun Microsystems, where he documents APIs for the Java programming language. In previous lives he programmed business applications, designed databases, taught technical classes, and documented RDBMS products. In his current incarnation he writes about internationalization and reflection APIs for the Java Tutorial.

Jim Inscore, author of Programming with Java IDL

Jim Inscore has worked as a technical writer for the past 18 years, documenting API for NeXT, Kaleida, Macromedia, Oracle, Objectivity, and a number of other companies. He is currently publications manager for enterprise, server, and multimedia technologies in Java Software.

In his spare time, Jim hangs out with his family and works on remodeling his house.

Monica Pawlan, author of Overview of JDK Features and Reference Objects

Monica Pawlan is a staff writer for the Java Developer Connection (JDC), and contributing author for the Java Tutorial. She has a background in 2D and 3D graphics, security, and database products, and loves to study and write about emerging technologies. When not writing, she spends her spare time gardening, studying classical piano, and dreaming of far away places--some of which she occasionally visits.

Andrew Quinn, author of JavaBeans: Java Platform Components

Andy Quinn is a Sun Microsystems technical writer who specializes in writing for software developers.

Alan Sommerer Author of The Java Archive (JAR) File Format and The Java Extension Mechanism

Before moving to Silicon Valley, Alan Sommerer was a physicist on the staff of the International Institute of Theoretical and Applied Physics at Iowa State University. After moving to California, he joined Warthman Associates in Palo Alto, where he did technical writing and applet programming for a variety of high- tech firms. Alan now writes documentation about the Java Development Kit for Sun Microsystems.

Beth Stearns, author of Using the Java Native Interface

Beth Stearns is the president of Computer Ease Publishing, a computer consulting firm she founded in 1982. Her client list includes Sun Microsystems Inc., Silicon Graphics Inc., Oracle Corporation, and Xerox Corporation, among others. Her Understanding EDT, a guide to Digital Equipment Corporation's text editor, has sold throughout the world. She received her B.S. degree from Cornell University and a Master's degree from Adelphi University.

Beth is an avid cyclist, hiker, gourmet cook, and Francophile, and she plans to retire with her two cats and husband to the southwest of France.

Jim Waldo, co-author of Using Java RMI

Jim Waldo is a Senior Staff Engineer with Sun Microsystems, where he leads a team developing a distributed programming infrastructure for Java. Before joining Sun's Java Software division, he was a Principle Investigator in Sun Labs, doing research into the areas of object-oriented programming and systems, distributed computing, and user environments. Jim is also on the faculty of Harvard University, where he teaches distributed computing in the department of computer science. He received his Ph.D. in philosophy from the University of Massachusetts (Amherst). He also holds M.A. degrees in both linguistics and philosophy.

Ann Wollrath, co-author of Using Java RMI

Ann Wollrath is a senior staff engineer with Sun Microsystems where she is the architect and project lead of the Java Remote Method Invocation system. Previously during her tenure at Sun Microsystems Laboratories and at the MITRE Corporation, she researched reliable, largenscale distributed systems and parallel computation. Wollrath received an M.S. in computer science from the University of Massachusetts, Lowell, and a B.S. in computer science from Merrimack College.

Acknowledgments

The editors would like to thank the authors who contributed to this volume. Their work on this book was in addition to their normal, crazy workload. We appreciate their hard work and enthusiasm for this project.

Our reviewers include a patient group of readers at Sun Microsystems, and our Internet readers who send us email to cheerfully point out our errors and help us revise our awkward sentences. In particular, we'd like to thank Tim Lindholm and Lisa Friendly for helping to review the trails in this book.

Our team managers, Lisa Friendly, Rick Levenson, and Stans Kleijnen, create a supportive work environment that helps us get our job done. Mike Hendrickson, our editorial advisor at Addison-Wesley, is a constant motivator. Sarah Weaver was the wonderful production manager on the book who kept us on schedule.

Evelyn Pyle was our eagle-eyed copy editor. The whole team at Addison-Wesley have been a pleasure to work with and continually strive for excellence on this and the other books in the series.



0201485583P04062001

Updates

Submit Errata

More Information

InformIT Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from InformIT and its family of brands. I can unsubscribe at any time.

Overview


Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information


To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.

Surveys

Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites, develop new products and services, conduct educational research and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.

Newsletters

If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email information@informit.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information


Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.

Security


Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.

Children


This site is not directed to children under the age of 13.

Marketing


Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information


If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.

Choice/Opt-out


Users can always make an informed choice as to whether they should proceed with certain services offered by InformIT. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.informit.com/u.aspx.

Sale of Personal Information


Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents


California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure


Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.

Links


This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact


Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice


We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020