class Singleton { public: static Singleton* getInstance() { static Singleton *p = new Singleton(); return p; } private: Singleton() {} ~Singleton() {} };