Hai Pinky,
Design pattern is the way to reduce the problem in design time rather than after the implementation of the project.
It provides the reusable solution for the problems which commonly occurs during the designing of the applications.
Lets take a example:
We have created an applications which is in 1 tier patterns i.e. there is one front end application which contains all the related code for the database interaction as well as the business logic.
Now we have kept the constraint in the stored procedure that if the emp sal is <10000, the record should not insert in to the database. So the record will go to the database and try to insert, from there it will fail and return back to the application. So here this is unnecessary call. If you cna restrict it to our desing and create a business layer which will take care of all these constraints, it will be good and the response time will be high for the applications.
Like this there are many scenaris where we use the design patterns to scale up our application and reduce the response time as well as we try to reduce the dependency between the components.
Due to these issue, the 2-tier, 3-tier and then n-tier applications came to the market.
After this there were still many issues with these patterns, then MVC(ASP.Net MVC 2, ASP.Net MVC 3, ASP.Net MVC4), MVP, MVVM, Prism Framework etc are in the market.
GoF(Gang Of Four) has classified the design patterns in to 3 ways:-
1. Creational Design patterns
2. Behavioral Design patterns
3. Structural Design patterns
Hope it will be helpful to you.
Regards,
Pawan Awasthi(DNS MVM)
+91 8123489140 (whatsApp), +60 14365 1476(Malaysia)
pawansoftit@gmail.com