SOLID code

SOLID as stated by ????

  • Single responsibility,
  •  Open closed principle,
  •  Liskov substitution principle,
  •  Interface segregation principle
  •  Dependency Inversion

These are five prnciples while doing class design




























SRP



Single Responsibility Principle



A class should have one, and only
one, reason to change.



OCP



Open Closed Principle



You should be able to extend a
classes behavior, without modifying it.



LSP



Liskov Substitution Principle



Derived classes must be
substitutable for their base classes.



ISP



Interface Segregation Principle



Make fine grained interfaces that
are client specific.



DIP



Dependency Inversion Principle



Depend on abstractions, not on
concretions.