Factory Method Design Pattern
Intent
We create objects without exposing the creation logic to users, we define an interface for creating objects, and allow subclasses to alter the type of objects that will be created after creating the objects in a superclass to prevent nasty cod...
metwalli.hashnode.dev2 min read