Removed heavy use of static methods, and made it into a normal singleton pattern