The factory is one of the most popular design patterns out there. It is used to simply the creation of the objects of different classes that inherit from a common super-class (or interface X) depending on some condition. The Recipe In order to create a factory for a class X: Create an XFactory class Add