Technical

Why Software Design Patterns?

Basically when you know patterns, you know solutions to problems that are extremely common in software engineering. In other words there is no need to Reinvent the Wheel. Learning design patterns is like learning from community. The appropriate use of design pattern make code readable and easy to maintain and rather I will say overall it makes the code more efficient.

Note: I have just started this section so it will take little time to complete.

What is a design pattern?

  • A design pattern is a widely accepted solution to a recurring design problem in OOP
  • A design pattern describes how to structure classes to meet a given requirement
  • Does not describe how to structure the entire application
  • Does not describe specific algorithms

GOF - Gang of Four defined 23 desing patterns in their famous book "Elements of Reusable Object-Oriented Software" The Gang of four authors are

  • Erich Gamma
  • Richard Helm
  • Ralph Johnson
  • John Vlissides

In technology circles you’ll often see this nicknamed shorted to GoF. Even though the GoF Design Patterns book was published over 20 years ago, it continues to be an Amazon best seller.

Creational Patterns

Creational patterns control the Object Creation. They don't let you instantiate the object directly. They abstract the object creation logic and give you an object that is suitable for particular situation.

Structural Patterns

Structural Patterns describe ways to compose large structure of classes and objects.

Behavioral Patterns

Behavioral patterns describe the ways to communicate the messages between objects.