What is a factory and why would I want to use one?
Factory is an object for creating other objects.
It creates objects without exposing the instantiation logic to the client.
Use this pattern when you don't want to expose object instantiation logic to the client/caller
Related posts:
Design Patterns: Factory vs Factory method vs Abstract Factory
What is the basic difference between the Factory and Abstract Factory Patterns?