Pages

Friday, November 08, 2013

The Structure of a Design Pattern

A pattern is presented in the form of a rule that establishes the relationship between a context, a system of forces that arises in the context and a configuration that allows these forces to resolve themselves in the context.

Component Elements of a Design Pattern

A design pattern should have a:
  • Pattern name and a description
  • Context outline - the contexts in which the pattern is effective in responding to the users needs.
  • Problem statement - a statement of the problem being addressed.
  • Solution - a description of how the problem is solved.
  • Design - a description of pattern's design and the user's behavior in interacting with it.
  • Implementation - a guide to how the pattern is implemented
  • Illustrations - a visual representation of classes in the pattern
  • Examples - an implementation of the pattern in the minimal form.
  • Co-requisites - supporting patterns needed.
  • Relations - other patterns that resemble this pattern.
  • Known usage - where and how the pattern is used.
  • Discussions - thoughts on the benefits of the pattern.
Though the initial cost for creating a pattern is really high, the value return from that can be quite worth it.

No comments:

Post a Comment