Table of Contents
Chapter 1: An Introduction to Java
Java As a Programming Platform
The Java "White Paper" Buzzwords
Java Applets and the Internet
A Short History of Java
Common Misconceptions about Java
Chapter 2: The Java Programming Environment
Installing the Java Development Kit
Choosing a Development Environment
Using the Command-Line Tools
Using an Integrated Development Environment
Running a Graphical Application
Building and Running Applets
Chapter 3: Fundamental Programming Structures in Java
A Simple Java Program
Comments
Data Types
Variables
Operators
Strings
Input and Output
Control Flow
Big Numbers
Arrays
Chapter 4: Objects and Classes
Introduction to Object-Oriented Programming
Using Predefined Classes
Defining Your Own Classes
Static Fields and Methods
Method Parameters
Object Construction
Packages
The Class Path
Documentation Comments
Class Design Hints
Chapter 5: Inheritance
Classes, Superclasses, and Subclasses
Object: The Cosmic Superclass
Generic Array Lists
Object Wrappers and Autoboxing
Methods with a Variable Number of Parameters
Enumeration Classes
Reflection
Design Hints for Inheritance
Chapter 6: Interfaces and Inner Classes
Interfaces
Object Cloning
Interfaces and Callbacks
Inner Classes
Proxies
Chapter 7: Graphics Programming
Introducing Swing
Creating a Frame
Positioning a Frame
Displaying Information in a Component
Working with 2D Shapes
Using Color
Using Special Fonts for Text
Displaying Images
Chapter 8: Event Handling
Basics of Event Handling
Actions
Mouse Events
The AWT Event Hierarchy
Chapter 9: User Interface Components with Swing
Swing and the Model-View-Controller Design Pattern
Introduction to Layout Management
Text Input
Choice Components
Menus
Sophisticated Layout Management
Dialog Boxes
Chapter 10: Deploying Applications and Applets
JAR Files
Java Web Start
Applets
Storage of Application Preferences
Chapter 11: Exceptions, Logging, Assertions, and Debugging
Dealing with Errors
Catching Exceptions
Tips for Using Exceptions
Using Assertions
Logging
Debugging Tips
Using a Debugger
Chapter 12: Generic Programming
Why Generic Programming?
Definition of a Simple Generic Class
Generic Methods
Bounds for Type Variables
Generic Code and the Virtual Machine
Restrictions and Limitations
Inheritance Rules for Generic Types
Wildcard Types
Reflection and Generics
Chapter 13: Collections
Collection Interfaces
Concrete Collections
The Collections Framework
Algorithms
Legacy Collections
Chapter 14: Multithreading
What Are Threads?
Interrupting Threads
Thread States
Thread Properties
Synchronization
Blocking Queues
Thread-Safe Collections
Callables and Futures
Executors
Synchronizers
Threads and Swing