Runnable examples of 21 Gang-of-Four patterns, each rewritten with modern language and library features instead of the textbook "abstract base class + virtual clone()" shape.
| File | Patterns |
|---|---|
creational.cpp |
Singleton, Factory Method, Abstract Factory, Builder, Prototype |
structural.cpp |
Adapter, Bridge, Composite, Decorator, Facade, Flyweight, Proxy |
behavioral.cpp |
Strategy, Observer, Command, State, Visitor/Interpreter, Template Method, Iterator, Chain of Responsibility, Memento |
reflection.cpp |
Factory/Visitor/Memento helpers using static reflection (P2996) |