The Object-Oriented Design Principles are the core of OOP programming, but I have seen most of the Asp.net Developers chasing design patterns like Factory Design Patterns, Singleton pattern, Decorator pattern, Adapter Pattern or Observer pattern, and not putting enough attention on learning Object-oriented analysis and design.
It's very important to learn the basics of Object-oriented programming like Abstraction, Encapsulation, Inheritance, Polymorphism. But, at the same time, it's equally important to know about object-oriented design principles. it will help you to create a modular and clean design, which would be easy to test in all scenarios, debugging, and maintain the code in the future.
SOLID Design Principles
There are five SOLID Design Principles as shown below list and OOD:
- Single Responsibility Principle (SRP)
- Open-Closed Principle (OCP)
- Liskov Substitution Principle (LSP)
- Interface Segregation Principle (ISP)
- Dependency Inversion Principle (DIP)
- DRY
- Delegation Principles (Don't repeat yourself)
Advantages of SOLID Design Principles in C#
- Maintainability
- Testability
- Flexibility and Extensibility
- Easy to debugging the code
- Parallel Development
Post a Comment (0)