Next: Find Classes
Up: C++ Design Issues
Previous: Never looking for a
As usual, there is no one right way of doing this. However the main steps are
regularly the followings:
- 1. Find the concepts/classes and their most fundamental relationships.
- 2. Refine classes by specifying the sets of operations on them. Classify
these operations. In particular, consider the needs for construction, copying, and
destruction. Consider minimalism, completeness, convience.
- 3. Refine classes by specifying their dependencies. Consider parametrization,
inheritance and use dependencies
- 4. Specify the interfaces. Separate functions into public and protected
operations. Specify the exact type of the operations on the classes.
These steps are in an iterative process. Typically, several loops through this
sequence are needed to produce a design one can confortably use for an initial
implementation or reimplementation.
Porkoláb Zoltán
2001-09-03