SRP - The Single Responsibility Principle

OCP - The Open-Closed Principle

  • A Module should be open for extension but closed for modification.

LSP - The Liskov Substitution Principle

  • A program that uses an interface must not be confused by an implementation of that interface. It is about sub-typing. All implementations of interfaces are subtypes of an interface. All duck-types are subtypes of an implied interface. And, every user of the base Simple code is code that maintains crisp subtype relationships.

ISP - The Interface Segregation Principle

  • Keep interfaces small so that users don’t end up depending on things they don’t need.

DIP - The Dependency Inversion Principle

  • Depend in the direction of abstraction. High level modules should not depend upon low level details. We want isolation of the high level abstractions from the low level details. That separation is achieved by carefully managing the dependencies within the system so that all source code dependencies, especially those that cross architectural boundaries, point towards high level abstractions, not low level details.