Skip to Content
Software Architecture Design Patterns in Java
book

Software Architecture Design Patterns in Java

by Partha Kuchana
April 2004
Intermediate to advanced
520 pages
10h 10m
English
Auerbach Publications
Content preview from Software Architecture Design Patterns in Java

19 DECORATOR

This pattern was previously described in GoF95.

DESCRIPTION

The Decorator Pattern is used to extend the functionality of an object dynamically without having to change the original class source or using inheritance. This is accomplished by creating an object wrapper referred to as a Decorator around the actual object.

CHARACTERISTICS OF A DECORATOR

  • The Decorator object is designed to have the same interface as the underlying object. This allows a client object to interact with the Decorator object in exactly the same manner as it would with the underlying actual object.
  • The Decorator object contains a reference to the actual object.
  • The Decorator object receives all requests (calls) from a client. It in turn forwards these calls ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Hands-On Software Architecture with Java

Hands-On Software Architecture with Java

Giuseppe Bonocore

Publisher Resources

ISBN: 9780203496213