Abstraction
Encapsulation
Polymorphism
Inheritance
Encapsulate what varies.
Favor composition over inheritance.
Program to an interace not implementation.
Strive for loosely coupled designs between objects that interact.
Classes should be open for extension but closed for modification.
Depend on abstractions. Do not depend on concrete classes.
Strategy:
Define a family of algorithms, encapsulates each one, and makes them interchargeable. Strategy lets algorithm vary independently from clients that use it.
Observer:
The Observer Pattern defines a one-to-many dependency between objects so that
when one object changes state, al of it's dependents are notified and updated automatically.
Decorator:
The Decorator Pattern attaches additional responsabilities to an object dynamically.
Decorators provide a flexible alternative to subclassing for extending functionality.
Factory Method:
The Factory Method Pattern defines an interface (abstract or simply a class) for creating objec, but lets subclasses decide which class to instantiate. Factory Method lets a class defer instantiation to subclasses.
Abstract Factory:
Provides an interface for creating families of related or dependent objects without specifying ther concrete classes.
Singleton:
Ensures a class has only one instance and provides a global point of access to it.
Strategy Pattern
Observer Pattern
Decorator Pattern
Factory Pattern
Singleton Pattern