Skip to content

Latest commit

 

History

History
18 lines (14 loc) · 671 Bytes

README.md

File metadata and controls

18 lines (14 loc) · 671 Bytes

Interface Segregation Principle

Acronym

  • S : Single Responsibility Principle (SRP).
  • O : Open closed Principle (OSP).
  • L : Liskov substitution Principle (LSP).
  • I : Interface Segregation Principle (ISP).
  • D : Dependency Inversion Principle (DIP).

Interface Segregation Principle:

  1. Many client-specific interfaces are better than one general-purpose interface.
  2. We should not enforce clients to implement interfaces that they don't use. Instead of creating one big interface we can break down it to smaller interfaces.

How not to do it

See ISP1 folder for source code.

How to do it

See ISPsolution folder for source code.