Complete Responsibility Rule

A corollary to the OneResponsibilityRule and OnceAndOnlyOnce. Once a class, method, or package takes on a responsibility, it should take full and sole responsibility. Clients should depend on it to take on the task, and not concern themselves with special cases, general setup, and the like.

Refactoring should proceed to move responsibility from the clients of the class into the class.

The responsibilities accepted by a unit of code should cohere (see CouplingAndCohesion).

This does not mean that responsibilities should be lumped into large classes. Responsibilities may in turn be subcontracted out in smaller responsibilities to smaller-level units. Large responsibilities belong to applications or packages. But there needs to be a clear boundary, whether it be module, class, method, package, or whatever, where we can say "the buck stops here". Further, this boundary should be minimal (OneResponsibilityRule).

--BobKerns [but don't let that stop you from treating this as DocumentMode]


EditText of this page (last edited May 24, 2002) or FindPage with title or text search