Structural Flashcards
Adapter
Converting an object into a type expected by the client. Adapter wraps the object and implements the type. Thus we use the object to provide functionality.
Bridge
Decouples major features from an object such that they can be added trough composition instead of inheritance. Wraps the abstract feature such that a varient of the feature can be specified.
Composite
Lets you create unit representations and return aggregated results.
Decorator
A decorator is extended to apply specialized functionality to an object. It does so by wrapping the object and implements it’s interface. This allows us to chain functionality by composition instead of inheritance.
Facade
Your avarage Helper class. Provides a simplified interface to one or more subsystems.
Flyweight
A way to separate shared state from objects. To free up RAM.
Proxy
Basically a decorator which controls access to an object. The only differense lies in it’s purpose.