Johnson and Foote's heuristics
From CSSEMediaWiki
(Difference between revisions)
m |
|||
Line 1: | Line 1: | ||
− | In | + | In their text, [[Johnson and Foote 1988]], Johnson & Foote describe a number of important heuristics. |
==Rules for Finding Standard Protocols== | ==Rules for Finding Standard Protocols== |
Revision as of 08:07, 8 August 2009
In their text, Johnson and Foote 1988, Johnson & Foote describe a number of important heuristics.
Contents |
Rules for Finding Standard Protocols
These heuristics determine a set of rules that standardising class design and structure.
- Rule 1: Recursion introduction
- Rule 2: Eliminate case analysis
- Rule 3: Reduce the number of arguments
- Rule 4: Reduce the size of methods
Rules for Finding Abstract Classes
These heuristics define methods of determining and extracting abstract classes.
- Rule 5: Class hierarchies should be deep and narrow
- Rule 6: The top of the class hierarchy should be abstract
- Rule 7: Minimize accesses to variables
- Rule 8: Subclasses should be specializations
Rules for Finding Frameworks
The heuristics describe how to find frameworks in OOD.
- Rule 9: Split large classes
- Rule 10: Factor implementation differences into subcomponents
- Rule 11: Separate methods that do not communicate
- Rule 12: Send messages to components instead of to self
- Rule 13: Reduce implicit parameter passing
External Resources
- Designing Reusable Classes - A summary