Builder
From CSSEMediaWiki
Revision as of 23:23, 6 October 2008 by Elliot Fisher (Talk | contribs)
The Builder pattern allows you to use the same construction process to create different representations of a complex object, and makes it easy to extend more representations in the future.
Use when
- There need to be different representations of the object to be constructed
- The creation algorithm should be independent of the parts of the object and how they are assembled
Structure
From the Gang of Four Design Patterns book: