Direkt zum Inhalt | Direkt zur Navigation

Benutzerspezifische Werkzeuge

Sie sind hier: Startseite / Growing Software as opposed to Building Software

Growing Software as opposed to Building Software

erstellt von Armin Stroß-Radschinski zuletzt verändert: 15.03.2015 13:31
In 1989 a group of software architects around Karl J. Lieberherr and Ian Holland were looking for a tool to simplify the implementation of Zeus, a hardware description language. While looking for a tool name related to Zeus, they choosed a sister of Zeus: Demeter. Later the idea of Demeter-style software development was promoted for structure-shy programming. The goal is coupling modules in object oriented development as loose as possible by making them only talk to themselves or the closest neighbours and not crossing over module hierarchies whenever possible. The manifest was casted into the "Law of Demeter", short: LoD and targets lowering dependencies and increase maintainability of software.
Growing Software as opposed to Building Software

Cleancode rules

The Law of Demeter (LoD) or principle of least knowledge is a design guideline for developing software, particularly object-oriented programs. In its general form, the LoD is a specific case of loose coupling. The guideline was proposed at Northeastern University towards the end of 1987, and can be succinctly summarized in each of the following ways:[1]

  • Each unit should have only limited knowledge about other units: only units "closely" related to the current unit.
  • Each unit should only talk to its friends; don't talk to strangers.
  • Only talk to your immediate friends.

The fundamental notion is that a given object should assume as little as possible about the structure or properties of anything else (including its subcomponents), in accordance with the principle of "information hiding".

It is so named for its origin in the Demeter Project, an adaptive programming and aspect-oriented programming effort. The project was named in honor of Demeter, “distribution-mother” and the Greek goddess of agriculture, to signify a bottom-up philosophy of programming which is also embodied in the law itself.

Conclusion: LoD is a good reminder how to keep software "soft".

more about this