Adopt Adapter

Software usually consists of a mixture of in-house and purchased software that must work together to produce a seamless user interface. But disparate software packages are not aware of each other's object models, so they can't work...

Follow the Chain of Responsibility

The Chain of Responsibility (CoR) pattern decouples the sender and receiver of a request by interposing a chain of objects between them. In this installment of Java Design Patterns, David Geary discusses the CoR pattern and two...

Make your apps fly

Allocating numerous objects can be detrimental to your application's performance. In this installment of Java Design Patterns, David Geary shows you how to implement the Flyweight design pattern to greatly reduce the number of objects...

Façade clears complexity

The Façade design pattern simplifies complex APIs by providing a simplified interface to a complex subsystem. In this installment of Java Design Patterns, David Geary explores a built-in Swing façade for creating dialog boxes and a...

How to navigate the deceptively simple Singleton pattern

The Singleton pattern is deceptively simple, even and especially for Java developers. In this classic JavaWorld article, David Geary demonstrates how Java developers implement singletons, with code examples for multithreading,...

An inside view of Observer

The Observer pattern lets you build extensible software with pluggable objects by allowing communication between loosely coupled objects. In his latest Java Design Patterns column, David Geary explores the Observer pattern, how it's...

A look at the Composite design pattern

The Composite design pattern lets you treat primitive and composite objects exactly the same. In his latest Java Design Patterns column, David Geary explores how to implement the Composite pattern and how to use it with the Tiles tag...

Take command of your software

The Command pattern lets an application framework make requests of application-specific objects, without the framework knowing the objects' exact type or the application-specific behavior they implement. In his latest Java Design...

Strategy for success

The Strategy design pattern embodies two fundamental tenets of object-oriented (OO) design: encapsulate the concept that varies and program to an interface, not an implementation. In this article, David Geary shows how to use the...

Take control with the Proxy design pattern

The Proxy design pattern lets you substitute a proxy for an object. In that capacity, proxies prove useful in many situations, ranging from Web services to Swing icons. In this latest Java Design Patterns installment, David Geary...

Amaze your developer friends with design patterns

Design patterns are proven techniques for implementing robust, malleable, reusable, and extensible object-oriented software. To launch his Java Design Patterns column, David Geary introduces design patterns to Java developers and...