[ fromfile: designpatterns.xml id: designpatterns ]
Design patterns are efficient and elegant solutions to common problems in object-oriented software design. They are high-level abstract templates that can be applied to particular kinds of design problems.
In their influential book,Design Patterns [Gamma95], Erich Gamma, Richard Helm, Ralph Johnson, and John Vlissides, often (affectionately) referred to as the "Gang of Four", analyzed 23 specific patterns. Each pattern has a section devoted to it, describing the following things.
A pattern name.
A description of the kinds of problems to which one might apply the pattern.
An abstract description of a design problem and how its solution can be obtained.
A discussion of the results and trade-offs that can occur when the pattern is applied.
Design patterns are used for many different purposes. Most describe how to separate code by responsibility. They are subdivided into three categories: Creational, Structural, and Behavioral. Structural patterns describe how to organize objects, and connect them together. Behavioral patterns describe how to organize code. Creational patterns describe how to organize code that manages object creation.
The Gang of Four assert that design patterns are "descriptions of communicating objects and classes that are customized to solve a general design problem in a particular context." As you continue to develop applications with Qt, you will see descriptions and examples of several design patterns.
Some of the commonly encountered design patterns arose from working around limitations in the more popular languages and APIs that were in use at the time they were cataloged. On the other hand, a modern, dynamic language like Python, has built-in support for several design patterns already, so implementing them in your own software is a natural benefit of learning that language. The same is true for Qt. You will work with several Qt classes that implement particular design patterns.
Generated: 2012-03-02 | © 2012 Alan Ezust and Paul Ezust. |