SOLID class design principles
Learn about SOLID class design principles and the Single Responsibility Principle.
We'll cover the following...
In the mid-1990s, Robert C. Martin gathered five principles for object-oriented class design, presenting them as the best guidelines for building a maintainable object-oriented system. Michael Feathers attached the acronym SOLID to these principles in the early 2000s.
- Single Responsibility Principle (SRP): Classes should have one reason to change. Keep classes small and single-purposed.