Advertisement
Guest User

Untitled

a guest
Jan 18th, 2017
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.35 KB | None | 0 0
  1. /**
  2. * @file Singleton.cpp part of @file Singleton.hpp
  3. * @version 2
  4. *
  5. * @author Denis Colesnicov <eugustus@gmail.com>
  6. * @date 2017/01/15
  7. *
  8. * @copyright WTFPL
  9. */
  10.  
  11. #include "Singleton.h"
  12.  
  13. Singleton* Singleton::m_instance = nullptr;
  14.  
  15. Singleton* Singleton::getInstance()
  16. {
  17. if(!m_instance){
  18. m_instance = new Singleton;
  19. }
  20. return m_instance;
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement