Design Through Reuse

References:

  1. Bernd Bruegge and Allen H. Dutoit, "Object-Oriented Software Engineering", Third Edition, Chapter 8
  2. Erich Gamma, Richard Helm, Ralph Johnson, and John Vlissides, "Design Patterns - Elements of Reusable Object-Oriented Software", Addison Wesley, 1995.

Concepts of Reuse

Reuse Through Inheritance

 

Reuse Through Frameworks

Adapting Commercial Off-The-Shelf ( COTS ) Software

Issues with Reuse

Design Patterns

( Handout )


Creational Patterns

Singleton

Prototype

Factory Method

Abstract Factory

Builder

Structural Patterns

Adapter

Bridge

Decorator

Facade

Proxy

  1. A remote proxy provides a stand-in for an object that is in a different address space, e.g. on a separate computer or on the hard drive instead of in RAM.
  2. A virtual proxy creates expensive objects on demand. For example a document may use proxies to save time by not loading in images that do not appear on the screen ( at the moment. )
  3. A protection proxy controls access to the original object.
  4. A smart reference provides more sophisticated indirect access than ordinary pointers, such as doing reference counting and garbage collection.

Composite

Flyweight

Behavioral Patterns

Observer

Command

Mediator

Chain of Responsibility

State

Memento

Interpreter

Iterator

Visitor

Strategy

Template Method