Limit hierarchy depth

From CSSEMediaWiki
Revision as of 10:01, 6 October 2008 by Tureiti Keith (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Riel's Heuristic #5.5: In practice, inheritance hierarchies should be no deeper than an average person can keep in his or her short-term memory. A popular value for this depth is six.

Description

Riel's Heuristic #5.5 suggests that inheritance hierarchies should be be no deeper than 6 levels. This heuristic is based on empirical studies with real world design problems. It was found that the designers with the most difficulty navigating their class hierarchies were those with hierarchies of 12 to 17 levels in depth. Upon redesigning the hierarchies to use five to seven levels, the task of navigation was purportedly easier.

A Proviso

There is a proviso on the depth of six, and that is that the designers do not have class hierarchy visualisation tools available. The designers suggested that, with access to tools that aid in class hierarchy visualisation, working with deep hierarchies would become easier: Closer to theory (Riel #5.4).

See Also

Personal tools