Alle boeken

Professioneel

Apps Over Coach Inloggen Begin met lezen

Computer Science · Begrippenlijst

Wat is Modularity, coupling, cohesion, information hiding, dependency inversion?

Ook bekend als: modularity · coupling · cohesion · information hiding · dependency inversion

Definition 30.3 University Computer Science — Year 3 · Hoofdstuk 30 — Software Engineering: Design, Testing and Maintenance

Modularity is the division of a program into modules that can be written, understood, tested and changed separately. Coupling is the degree to which one module depends on the details of another; cohesion is the degree to which the parts of one module serve a single purpose. Information hiding is the choice of module boundaries so that each module hides a design decision likely to change, behind an interface that does not reveal it. Dependency inversion makes a high-level module and a low-level one both depend on an interface owned by the high-level side, instead of the high-level module depending on the low-level one.

Dependency inversion. Before, the service depends on the storage library and on the system clock. After, it depends on an interface that it owns; the SQLite class and any test double depend on that interface, and the arrows from the low-level side point up.
Dependency inversion. Before, the service depends on the storage library and on the system clock. After, it depends on an interface that it owns; the SQLite class and any test double depend on that interface, and the arrows from the low-level side point up.
Lees in het hoofdstuk →