Part III: Design Patterns

Part Overview

This part introduces design patterns: what they are and how to use them. Four patterns pertinent to the CAD/CAM problem (Chapter 3, “A Problem That Cries Out for Flexible Code”) are described. They are presented individually and then related to the earlier problem. In learning these patterns, I emphasize the object-oriented strategies espoused by the Gang of Four (as the authors Gamma, Helm, Johnson, and Vlissides are often referred to) in their seminal work, Design Patterns: Elements of Reusable Object-Oriented Software.

Chapter Discusses These Topics
5
  • An introduction to design patterns.

  • The concept of design patterns, their origins in architecture, and how they apply in the discipline of software design.

  • The motivations for studying design patterns.

6
  • The Facade pattern: what it is, where it is used, and how it is implemented.

  • How the Facade pattern relates to the CAD/CAM problem.

7
  • The Adapter pattern: what it is, where it is used, and how it is implemented.

  • Comparison between the Adapter pattern and the Facade pattern.

  • How the Adapter pattern relates to the CAD/CAM problem.

8
  • Some important concepts in object-oriented programming: polymorphism, abstraction, classes, and encapsulation. It uses what has been learned in Chapters 57.

9
  • The Bridge pattern. This pattern is quite a bit more complex than the previous patterns. It is also much more useful; therefore, I go into great detail with the Bridge pattern.

  • How the Bridge pattern relates to the CAD/CAM problem.

10
  • The Abstract Factory pattern, which focuses on creating families of objects. What the pattern is, how it is used and implemented.

  • How the Abstract Factory pattern relates to the CAD/CAM problem.

At the end of this section, the reader will understand what design patterns are, why they are useful, and will be familiar with four specific patterns. The reader will also see how these patterns relate to the earlier CAD/CAM problem. This information, however, may not be enough to create a better design than we arrived at by overrelying on inheritance. However, the stage is set for using patterns in a way different from the way most design pattern practitioners use them.


..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.225.255.86