Design patterns! Why they are important in software development?

In order to solve problems of programmers about writing a lot of code in which the most important thing is time not enough to develop products for customers. Therefore, design patterns are formalized best practices that the programmer can use to solve common problems when designing an application or system.


Design Pattern is a technique in object-oriented programming, it is quite important and every programmer is better if knowing it. Used frequently in OOP languages, design pattern will give you the "design" solutions to solve common problems, common in programming. The problems you encounter may be you invent workarounds but maybe it's not optimal. Design Pattern helps you solve the most optimal way, gives you the solution in OOP programming.

There are 3 basic types of design patterns as follows:

Creational Pattern
Consist of "Abstract Factory, Factory Method, Singleton, Builder, Prototype". It will help you in initializing the object, as you know to create you must use the new keyword, creational pattern group will use some tricks to create objects that you will not see this keyword.

Structural Pattern
Consist of "Adapter, Bridge, Composite, Decorator, Facade, Proxy và Flyweight..". It used to establish, define relationships between objects.

Behavioral Pattern
Consist of "Interpreter, Template Method, Chain of Responsibility, Command, Iterator, Mediator, Memento, Observer, State, Strategy and Visitor..". This group used in the implementation of the behavior of objects.

Why should use Design Pattern?
Design Pattern provides solutions in general form, to help speed up software development by giving the test model, development model has passed the test. Effective software design requires considering issues will arise in the process of realization (an implementation). Reusing the design pattern helps avoid potential problems can cause large errors, easier upgrades, maintenance later.

A big advantage to using a design pattern that other programmers will be able to easily recognize it (especially if you use a good naming convention).

When?
That's when you want to keep your program is really simple. The use of design pattern will help us reduce the time and effort to think out the workarounds for these issues have been resolved. You can read through the book "Head First Design Patterns" to have an overview of the design pattern.


If you liked this article

Let's subscribe the updates of Scuti!
Share on Google Plus

About Anonymous

This is a short description in the author block about the author. You edit it by entering text in the "Biographical Info" field in the user admin panel.
    Blogger Comment
    Facebook Comment

0 Comments:

Post a Comment