SOLID
- Definition
In software engineering, SOLID is an acronym for five design principles intended to make object-oriented designs more understandable, flexible, and maintainable.
- Breakdown of the Acronym
Letter | Meaning |
---|---|
S | The Single Responsibility principle says that Every class should have only one responsibility. |
O | The Open-Closed principle says that Software entities should be open for extension, but closed for modification. |
L | The Liskov Substitution principle says that Functions that use pointers or references to base classes must be able to use objects of derived classes without knowing it. See also design by contract. |
I | The Interface Segregation principle says that Clients should not be forced to depend upon interfaces that they do not use". |
D | The Dependency Inversion principle instructs you to Depend upon abstractions, not concretions. |
Although the SOLID principles apply to any object-oriented design, they can also form a core philosophy for methodologies such as agile development or adaptive software development.