CSC/ECE 517 Fall 2009/wiki3 5 SD: Difference between revisions
Jump to navigation
Jump to search
Line 7: | Line 7: | ||
<li>Abstractions should not depend upon details. Details should depend upon abstractions.</li> | <li>Abstractions should not depend upon details. Details should depend upon abstractions.</li> | ||
</ol> | </ol> | ||
<h3>Description</h3> | |||
In conventional application architecture, lower-level components are designed to be consumed by higher-level components which enable increasingly complex systems to be built. In this composition, higher-level components depend directly upon lower-level components to achieve some task. This dependency upon lower-level components makes applications rigid, fragile and immobile. |
Revision as of 00:56, 12 November 2009
Dependency inversion principle
The Dependency Inversion Principle(DIP) states that:
- High-level modules should not depend on low-level modules. Both should depend on abstractions.
- Abstractions should not depend upon details. Details should depend upon abstractions.
Description
In conventional application architecture, lower-level components are designed to be consumed by higher-level components which enable increasingly complex systems to be built. In this composition, higher-level components depend directly upon lower-level components to achieve some task. This dependency upon lower-level components makes applications rigid, fragile and immobile.