Kinect Scol plugin
Public Member Functions | Static Public Member Functions | Protected Member Functions | Static Protected Attributes | List of all members
Singleton< DERIVATED_CLASS > Class Template Reference

Create Singleton type. . More...

#include <Singleton.h>

Public Member Functions

 Singleton ()
 
 ~Singleton ()
 

Static Public Member Functions

static DERIVATED_CLASS & GetSingleton ()
 
static DERIVATED_CLASS * GetSingletonPtr ()
 

Protected Member Functions

template<>
DeviceManagerinstance
 

Static Protected Attributes

static DERIVATED_CLASS * instance
 

Detailed Description

template<typename DERIVATED_CLASS>
class Singleton< DERIVATED_CLASS >

Create Singleton type. .

A singleton class is a class that could have only one instance. Furthemore, the instance of the child class can be accessed from everywhere in the code, due to the statics functions GetSingleton and GetSingletonPtr.

Version
1.0
Date
february 2011

Definition at line 41 of file Singleton.h.

Constructor & Destructor Documentation

◆ Singleton()

template<typename DERIVATED_CLASS >
Singleton< DERIVATED_CLASS >::Singleton ( )
inline

Constructor.

Definition at line 72 of file Singleton.h.

◆ ~Singleton()

template<typename DERIVATED_CLASS >
Singleton< DERIVATED_CLASS >::~Singleton ( )
inline

Destructor.

Definition at line 83 of file Singleton.h.

Member Function Documentation

◆ GetSingleton()

template<typename DERIVATED_CLASS >
DERIVATED_CLASS & Singleton< DERIVATED_CLASS >::GetSingleton ( )
static

Get the singleton instance.

Definition at line 89 of file Singleton.h.

◆ GetSingletonPtr()

template<typename DERIVATED_CLASS >
DERIVATED_CLASS * Singleton< DERIVATED_CLASS >::GetSingletonPtr ( )
static

Get the pointer of the singleton instance.

Definition at line 95 of file Singleton.h.


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