Explore Topics
Field f = Box.class.getDeclaredField("value");
f.setAccessible(true);
f.setInt(box, 99);class Utils {
void printDate() { ... }
double computeSqrt(int) { ... }
void sendEmail(String) { ... }
}Rank 7/7 coupling, rank 7/7 cohesion.
(rank 1 = best, 7 = worst)
In 1974, three IBM engineers — Wayne Stevens, Glenford Myers and Larry Constantine — published "Structured Design", a paper that asked a deceptively simple question: what makes one decomposition of a program better than another? Their answer was a pair of metrics. Coupling measures how strongly modules depend on each other; cohesion measures how unified the work inside one module is. Decades before SOLID and GRASP, this two-axis model gave every design decision a coordinate. Today, every named principle you know is really an instruction for moving toward "low coupling × high cohesion" on the 2-D grid.
- Stevens, Myers, Constantine — "Structured Design", IBM Systems Journal (1974)
- Coupling: strength of inter-module dependencies (lower is better)
- Cohesion: degree to which a module's members serve one purpose (higher is better)
- Seven coupling levels, seven cohesion levels — a 7×7 grid of design quality
- SOLID, GRASP, DRY, KISS — all are SHORTCUTS for navigating this same grid
- Originally about procedural modules; the metric transfers cleanly to classes
- ✦Predates and underpins every modern OO principle — historical foundation
- ✦Provides a CONTINUOUS quality scale (not binary "good/bad")
- ✦Maps directly to maintenance cost — ripple-change studies validate the metric
- ✦Language-agnostic: works for Java, Python, microservices, even hardware modules
- △The seven levels are nominal categories — there is no precise quantification
- △Different authors disagree on edge cases (External coupling: a level or a Common variant?)
- △Easy to misuse as "more decomposition is always better" — leads to over-fragmentation
- △Cohesion is harder to measure than coupling; partly subjective