User Tools

Site Tools


principles:law_of_demeter

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
Next revisionBoth sides next revision
principles:law_of_demeter [2013-02-25 16:20] – minor improvements christianprinciples:law_of_demeter [2021-09-02 12:32] – old revision restored (2021-05-11 22:01) 65.21.179.175
Line 52: Line 52:
  
   * [[Low Coupling]] (LC): The goal of LoD is to reduce coupling by reducing the knowledge of a class about other classes.   * [[Low Coupling]] (LC): The goal of LoD is to reduce coupling by reducing the knowledge of a class about other classes.
-  * [[Tell, Don't Ask/Information Expert]] (TdA/IE)+  * [[Tell, Don't Ask/Information Expert]] (TdA/IE): LoD is more specific than TdA/IE because TdA/IE can be applied in a wider context (e.g. for responsibility assignment). Applying TdA leads to solutions which are good according to LoD. Note that the reverse is not true: Accoring to LoD you may get and set values from an object passed as a parameter to a method.
  
 ==== Specializations ==== ==== Specializations ====
Line 67: Line 67:
  
  
-===== Example =====+===== Examples =====
  
  
principles/law_of_demeter.txt · Last modified: 2021-10-18 21:52 by christian