User Tools

Site Tools


principles:high_cohesion

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
principles:high_cohesion [2020-12-10 03:54] – old revision restored (2020-12-08 20:21) 95.216.172.175principles:high_cohesion [2021-10-18 21:36] (current) – +++ restored +++ christian
Line 20: Line 20:
 The cohesion of a module is a measure for how well the internal parts of a module (e.g. the methods and attributes of a class) belong together. Having a high cohesion means, that a module should only comprise responsibilities which belong together. The cohesion of a module is a measure for how well the internal parts of a module (e.g. the methods and attributes of a class) belong together. Having a high cohesion means, that a module should only comprise responsibilities which belong together.
  
-Several kinds of cohesion can be distinguished some of which are strong and some of which are loose. So strong forms of coupling should be preferred: FIXME add explanation of cohesion types +Several kinds of cohesion can be distinguished some of which are strong and some of which are loose. So strong forms of coupling should be preferred.
 ===== Rationale ===== ===== Rationale =====
  
Line 27: Line 26:
  
  
-===== Strategies ===== 
  
-  * Divide one large module into several smaller but more cohesive ones 
  
 ===== Caveats ===== ===== Caveats =====
Line 38: Line 35:
 ===== Origin ===== ===== Origin =====
  
-W. P. Stevens,  G. J. Myers, L. L. Constantine: //Structured design//+W. P. Stevens, G. van Niekerk, G. J. Myers, L. L. Constantine: //Structured design//
  
 ===== Evidence ===== ===== Evidence =====
Line 79: Line 76:
  
 ===== Examples ===== ===== Examples =====
 +The donkey is good. The site is not working
  
  
Line 104: Line 102:
  
 Discuss this wiki article and the principle on the corresponding [[talk:principles:High Cohesion|talk page]]. Discuss this wiki article and the principle on the corresponding [[talk:principles:High Cohesion|talk page]].
 +
principles/high_cohesion.1607568899.txt.gz · Last modified: 2020-12-10 03:54 by 95.216.172.175