Design Pattern: As the name suggests, design patterns are set of patterns used in software design, which provide solution to a commonly occurring problem. Design patterns are formalized best practices that the programmer can use to solve common problems when designing an application or system.
In other words, Design patterns are structured approach to computer programming and its architecture.
Patterns are about reusable designs and interactions of objects.
Gang of Four: The 23 Gang of Four (GoF) patterns are generally considered the foundation for all other patterns. They are categorized in three groups: Creational, Structural, and Behavioral (for a complete list see below).
|Factory Pattern||Creates an instance of several derived classes|
|Abstract factory||Creates an instance of several families of classes|
|Builder Pattern||Separates object construction from its representation|
|Prototype Pattern||A fully initialized instance to be copied or cloned|
|Singelton Pattern||A class of which only a single instance can exist|
|Facade Pattern||A single class that represents an entire subsystem|
|Decorator Pattern||Add responsibilities to objects dynamically|
|Composite Pattern||A tree structure of simple and composite objects|
|Adapter Pattern||A fully initialized instance to be copied or cloned|
|Bridge Pattern||Separates an object’s interface from its implementation|
|Proxy Pattern||An object representing another object|
|Flyweight Pattern||A fine-grained instance used for efficient sharing|
|Chain of Responsibility||A way of passing a request between a chain of objects|
|Mediator Pattern||Defines simplified communication between classes|
|Observer Pattern||A way of notifying change to a number of classes|
|Visitor Pattern||Defines a new operation to a class without change|
|Iterator Pattern||Sequentially access the elements of a collection|
|Interpreter Pattern||A way to include language elements in a program|
|Memento Pattern||Capture and restore an object’s internal state|
|State Pattern||Alter an object’s behavior when its state changes|
|Strategy Pattern||Encapsulates an algorithm inside a class|
|Command Pattern||Encapsulate a command request as an object|
|Template Method||Defer the exact steps of an algorithm to a subclass|
Further read: To know more about Design Patterns please see the following links.