Added alias names for GOF patterns #267
This commit is contained in:
parent
fe63c9cec4
commit
c02e65fa3a
@ -9,6 +9,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Kit
|
||||
|
||||
**Intent:** Provide an interface for creating families of related or dependent
|
||||
objects without specifying their concrete classes.
|
||||
|
||||
|
@ -9,6 +9,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Wrapper
|
||||
|
||||
**Intent:** Convert the interface of a class into another interface the clients
|
||||
expect. Adapter lets classes work together that couldn't otherwise because of
|
||||
incompatible interfaces.
|
||||
|
@ -9,6 +9,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Handle/Body
|
||||
|
||||
**Intent:** Decouple an abstraction from its implementation so that the two can
|
||||
vary independently.
|
||||
|
||||
|
@ -9,6 +9,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Action, Transaction
|
||||
|
||||
**Intent:** Encapsulate a request as an object, thereby letting you
|
||||
parameterize clients with different requests, queue or log requests, and
|
||||
support undoable operations.
|
||||
|
@ -9,6 +9,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Wrapper
|
||||
|
||||
**Intent:** Attach additional responsibilities to an object dynamically.
|
||||
Decorators provide a flexible alternative to subclassing for extending
|
||||
functionality.
|
||||
|
@ -10,6 +10,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Virtual Constructor
|
||||
|
||||
**Intent:** Define an interface for creating an object, but let subclasses
|
||||
decide which class to instantiate. Factory Method lets a class defer
|
||||
instantiation to subclasses.
|
||||
|
@ -10,6 +10,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Cursor
|
||||
|
||||
**Intent:** Provide a way to access the elements of an aggregate object
|
||||
sequentially without exposing its underlying representation.
|
||||
|
||||
|
@ -9,6 +9,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Token
|
||||
|
||||
**Intent:** Without violating encapsulation, capture and externalize an
|
||||
object's internal state so that the object can be restored to this state later.
|
||||
|
||||
|
@ -10,6 +10,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Dependents, Publish-Subscribe
|
||||
|
||||
**Intent:** Define a one-to-many dependency between objects so that when one
|
||||
object changes state, all its dependents are notified and updated
|
||||
automatically.
|
||||
|
@ -10,6 +10,8 @@ tags:
|
||||
- Difficulty-Intermediate
|
||||
---
|
||||
|
||||
**Also known as:** Surrogate
|
||||
|
||||
**Intent:** Provide a surrogate or placeholder for another object to control
|
||||
access to it.
|
||||
|
||||
|
@ -10,6 +10,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Objects for States
|
||||
|
||||
**Intent:** Allow an object to alter its behavior when its internal state
|
||||
changes. The object will appear to change its class.
|
||||
|
||||
|
@ -10,6 +10,8 @@ tags:
|
||||
- Gang Of Four
|
||||
---
|
||||
|
||||
**Also known as:** Policy
|
||||
|
||||
**Intent:** Define a family of algorithms, encapsulate each one, and make them
|
||||
interchangeable. Strategy lets the algorithm vary independently from clients
|
||||
that use it.
|
||||
|
Loading…
x
Reference in New Issue
Block a user