Summary

In this chapter, I have shown how patterns illustrate two powerful design strategies:

  • Design from context

  • Encapsulate variations in classes

These strategies allow us to defer decisions until we can see the ramifications of these decisions. Looking at the context from which we are designing gives us better designs.

By encapsulating variation, I can accommodate many future variations that may arise but would not be accommodated when I do not try to make my designs more general-purpose. This is critical for those projects that do not have all of the resources you would like to have (in other words, all projects). By encapsulating variation appropriately, I can implement only those features I need without sacrificing future quality. Trying to figure out and accommodate all possible variations typically does not lead to better systems but often leads to no system at all. This is called paralysis by analysis.

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

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