Nui Engine
A game engine framework
Loading...
Searching...
No Matches
Nui::Singleton< T > Class Template Referencefinal

Template class for creating a singleton instance of a class. More...

#include <Singleton.h>

Public Member Functions

 Singleton (Singleton &&)=delete
 
 Singleton (const Singleton &)=delete
 
Singletonoperator= (Singleton &&)=delete
 
Singletonoperator= (Singleton &)=delete
 

Static Public Member Functions

static T & Get () noexcept
 Get the singleton instance.
 
static void Destroy () noexcept
 Destroy the singleton instance.
 

Detailed Description

template<typename T>
class Nui::Singleton< T >

Template class for creating a singleton instance of a class.

Template Parameters
TThe type of the class to be made a singleton.

Member Function Documentation

◆ Get()

template<typename T >
static T & Nui::Singleton< T >::Get ( )
inlinestaticnoexcept

Get the singleton instance.

Returns
T& A reference to the singleton instance.

The documentation for this class was generated from the following file: