Added Singleton/Factory pattern
Added Singleton/Factory pattern