An open API service indexing awesome lists of open source software.

https://github.com/serhatyamann/design_patterns

Design Patterns explanations and examples.
https://github.com/serhatyamann/design_patterns

adapter-pattern behavioral-design-patterns bridge-pattern builder-pattern chain-of-responsibility-pattern creational-design-patterns decorator-pattern design-patterns factory-pattern mediator-pattern observer-pattern singleton-pattern structural-design-patterns

Last synced: 7 months ago
JSON representation

Design Patterns explanations and examples.

Awesome Lists containing this project

README

          

# DESIGN PATTERNS

#### Design patterns are solutions to software design problems you find again and again in real-world application development. Patterns are about reusable designs and interactions of objects. They are categorized in three groups: Creational, Structural, and Behavioral.

## Creational Patterns

### [Singleton Pattern](https://github.com/serhatyamann/DESIGN_PATTERNS/tree/master/Singleton_Pattern)

#### The Singleton design pattern ensures a class has only one instance and provide a global point of access to it.

#### A visualization of the classes and objects participating in this pattern.
![Singleton](https://user-images.githubusercontent.com/25529312/139563016-f17a49c7-c538-4e4d-9046-f462903d34eb.png)

### [Factory Method Pattern](https://github.com/serhatyamann/DESIGN_PATTERNS/tree/master/Factory_Method_Pattern)

#### The Factory Method design pattern defines an interface for creating an object, but let subclasses decide which class to instantiate. This pattern lets a class defer instantiation to subclasses.

#### A visualization of the classes and objects participating in this pattern.
![factory](https://user-images.githubusercontent.com/25529312/139563021-ad0cdde9-5eda-4bc1-95cf-04ed9222e9e6.png)

## Structural Patterns

### [Decorator Pattern](https://github.com/serhatyamann/DESIGN_PATTERNS/tree/master/Decorator_Pattern)

#### The Decorator design pattern attaches additional responsibilities to an object dynamically. This pattern provide a flexible alternative to subclassing for extending functionality.

#### A visualization of the classes and objects participating in this pattern.
![decorator](https://user-images.githubusercontent.com/25529312/139563139-1261f29d-af1e-4c81-b078-9802526041a4.png)

## Behavioral Patterns

### [Chain of Responsibility Pattern](https://github.com/serhatyamann/DESIGN_PATTERNS/tree/master/Chain_of_Responsibility_Pattern)

#### The Chain of Responsibility design pattern avoids coupling the sender of a request to its receiver by giving more than one object a chance to handle the request. This pattern chains the receiving objects and passes the request along the chain until an object handles it.

#### A visualization of the classes and objects participating in this pattern.
![chain](https://user-images.githubusercontent.com/25529312/139563170-6e278713-120c-44a8-adbb-6291b7767318.png)