The Gang of Four Design Patterns Simplified
The Gang of Four Design Patterns are often hard to get .
Most of the articles on the internet are generic or too complicated to understand. This book solves this by providing an easier explanation of all the 23 design patterns with use cases implemented in Java and with link to GitHub.
Every design pattern is presented with an use case , the solution in java and the link to Github.
Once you finish this book , you will gain more confidence about implementing design patterns in your day to day programming.
Deals with how to create objects.
Singleton – Create a single instance of an object.
Prototype– Use an existing object by cloning it.
Factory Method – Delegate creation of an object to another object.
Abstract Factory – Delegate creation of a group of related objects to another object.
Builder – Delegate creation of a complex object to another object.
Deals with how to structure objects.
Adapter – Make two incompatible interfaces work together.
Bridge – Separate abstraction and implementation.
Composite – Treat part-whole hierarchy the same way.
Decorator – Add responsibilities to an object dynamically.
Facade – Provide a single interface for a group of related operations.
Flyweight – Reuse objects than creating new ones.
Proxy – Protect access to an object.
Deals with how to communicate between objects.
Chain of Responsibility – Allow different objects to carry out a responsibility.
Command – Encapsulate requests as separate objects.
Mediator – Act as a broker for communication between objects.
Template – Provide basic template of an algorithm to implement.
Strategy – Encapsulate different algorithms using separate objects which can be chosen at run time.
State – Encapsulate state specific behavior in a separate object.
Observer – Intimate group of objects when a change occurs.
Memento – Allow to revert an object’s state.
Iterator – Provide a generic way to iterate through collection of objects.
Interpreter – Represent a grammar using an object.
Visitor – Add new responsibilities to an object without changing its existing behavior.
Note : The original book by the Gang of Four was referred for these posts.
About the author:
I am Vijay , a full stack developer and a Tech Manager working in a multi national IT company. I have over 13 years of experience in the IT industry and have spent major part of my career working on Java and related technologies. In this book, I have tried to present the design patterns by the Gang of Four in a simplistic way yet not compromising on the quality of the content.
An ebook with all the 23 design patterns explained in simple language with use cases and code.