Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Singleton final {
- private:
- Singleton() {
- // ... constructor
- }
- ~Singleton() {
- // ... destructor
- }
- // ... instance members
- public:
- static Singleton& instance() { static Singleton _x; return _x; }
- // ... instance members
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement