Design Patterns Series 1 - Introduction

In these series I will learn the design patterns with you. There are about 23 patterns (Factory, Decorator, Strategy, ... etc..). I will start with a small introduction about design patterns, then I will explain one or at most two patterns in each post with sample code in C#.

What is the design pattern?
In a simple words, design pattern is a tested solution to a standard programming problem.
In other words, design patterns are solutions to programming problems that automatically implement good design techniques.

Why do we need to learn design patterns? 
When you faces a programming problem, instead of trying to solve it by your techniques. you should remember you have not to re-invent the wheel. this problem had been faced before and experts solved it and put general and tested solution for it. So if you know the design patterns you will use the appropriate pattern to solve your problem.

Design patterns are intended to help you handle change as you have to adapt your code to new and unforeseen circumstances.

Using design pattern will be helpful and how?
design patterns will make your solution easily reusable, extendable, and maintainable. when you are working on a problem, you don't care about reuse, extensibility, or maintainability but in the future when you want to modify your code you will spend more time than you spent in solving the problem itself.

I think this is the time to start learning the design patterns itself. I am learning it from Design Patterns For Dummies. It is my project manager recommendation.

here is a list of design patterns posts
  1. Design Patterns Series 2 - Strategy Pattern
  2. Design Patterns Series 3 - Decorator Pattern
  3. Design Patterns Series 4 - Factory Pattern
  4. Design Patterns Series 5 - Observer Pattern
  5. Design Patterns Series 6 - Chain Of Responsibility
  6. Design Patterns Series 7 - Singleton Pattern
  7. Design Patterns Series 8 - Flyweight Pattern
  8. Design Patterns Series 9 - Adapter Pattern
  9. Design Patterns Series 10 - Facade Pattern
  10. Design Patterns Series 11 - Template Method Pattern
  11. Design Patterns Series 12 - Builder Pattern
  12. Design Patterns Series 13 - Iterator Pattern
  13. Design Patterns Series 14 - Composite Pattern
  14. Design Patterns Series 15 - State Pattern
  15. Design Patterns Series 16 - Command Pattern
  16. Design Patterns Series 17 - Mediator Pattern
  17. Design Patterns Series 18 - More Patterns
  18. Design Patterns Series 19 - Circular Buffer Pattern
  19. Design Patterns Series 20 - Double Buffer, Recycle Bin, and MVC Patterns
  20. Design Patterns Series 21 - How to create your own pattern?


Popular posts from this blog

Android : How to change progress bar color at runtime programmatically?

ASP.Net MVC : Conditional Validation using ValidationAttribute

How to fire RowCommand event of nested GridView?