A design pattern is a general solution to the problems that developers face during software development.
It's not necessary to use design patterns but they make code more understandable and readable. Each design pattern solves a particular problem.
There are mainly 3 types of design patterns:
1. Creational
These design patterns provide a way to create class objects while hiding their creation logic. i.e, the object need not to be created directly using new operator. Below are the types of creational design patterns.
- Factory Method
- Abstract Method
- Singleton
- Builder
- Prototype
2. Structural
Comments
Post a Comment