25 # ifndef DSGSINGLETON_H 26 # define DSGSINGLETON_H 64 static std::unique_ptr<Singleton<T>> instance;
89 if (instance.get() ==
nullptr)
92 return static_cast<T *
>(instance.get());
105 template <
typename T>
107 std::unique_ptr<Singleton<T>>(
nullptr);
111 # endif // DSGSINGLETON_H Definition: singleton.H:62
static T & get_instance()
Definition: singleton.H:99
static T * get_ptr_instance()
Definition: singleton.H:87
Singleton & operator=(const Singleton< T > &)=delete
Singleton()
Definition: singleton.H:67
virtual ~Singleton()
Definition: singleton.H:78