class MySingleton 
{
public:
   static MySingleton& getInstance() {
      static MySingleton instance;
      return instance;
   }
// other non-static member function

private:
  // Private constructor 
   MySingleton() {};

   // Prevent copy-construction
   MySingleton (MySingleton const& copy); // not implemented
  
   // Prevent assignment
   MySingleton& operator = (MySingleton const& copy); // not implemented
};



