ITK  5.4.0
Insight Toolkit
Classes | Public Types | Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
itk::SingletonIndex Class Reference

#include <itkSingleton.h>

Detailed Description

Implementation detail.

Definition at line 47 of file itkSingleton.h.

+ Collaboration diagram for itk::SingletonIndex:

Classes

struct  GlobalObject
 

Public Types

using Self = SingletonIndex
 

Public Member Functions

template<typename T >
T * GetGlobalInstance (const char *globalName)
 
template<typename T >
void SetGlobalInstance (const char *globalName, T *global, std::function< void()> deleteFunc)
 

Private Member Functions

void * GetGlobalInstancePrivate (const char *globalName)
 
void SetGlobalInstancePrivate (const char *globalName, GlobalObject globalObject)
 

Private Attributes

std::map< std::string, GlobalObjectm_GlobalObjects
 

Static Private Attributes

static Selfm_Instance
 
 ~SingletonIndex ()
 
static SelfGetInstance ()
 
static void SetInstance (Self *instance)
 

Member Typedef Documentation

◆ Self

Standard class types.

Definition at line 51 of file itkSingleton.h.

Constructor & Destructor Documentation

◆ ~SingletonIndex()

itk::SingletonIndex::~SingletonIndex ( )

Set/Get the pointer to GlobalSingleton. Note that SetGlobalSingleton is not concurrent thread safe.

Member Function Documentation

◆ GetGlobalInstance()

template<typename T >
T* itk::SingletonIndex::GetGlobalInstance ( const char *  globalName)
inline

Definition at line 63 of file itkSingleton.h.

Referenced by itk::Singleton().

◆ GetGlobalInstancePrivate()

void* itk::SingletonIndex::GetGlobalInstancePrivate ( const char *  globalName)
private

◆ GetInstance()

static Self* itk::SingletonIndex::GetInstance ( )
static

Set/Get the pointer to GlobalSingleton. Note that SetGlobalSingleton is not concurrent thread safe.

Referenced by itk::Singleton().

◆ SetGlobalInstance()

template<typename T >
void itk::SingletonIndex::SetGlobalInstance ( const char *  globalName,
T *  global,
std::function< void()>  deleteFunc 
)
inline

Definition at line 73 of file itkSingleton.h.

Referenced by itk::Singleton().

◆ SetGlobalInstancePrivate()

void itk::SingletonIndex::SetGlobalInstancePrivate ( const char *  globalName,
GlobalObject  globalObject 
)
private

◆ SetInstance()

static void itk::SingletonIndex::SetInstance ( Self instance)
static

Set/Get the pointer to GlobalSingleton. Note that SetGlobalSingleton is not concurrent thread safe.

Member Data Documentation

◆ m_GlobalObjects

std::map<std::string, GlobalObject> itk::SingletonIndex::m_GlobalObjects
private

The static GlobalSingleton. This is initialized to nullptr as the first stage of static initialization. It is then populated on the first call to itk::Singleton::Modified() but it can be overridden with SetGlobalSingleton().

Definition at line 127 of file itkSingleton.h.

◆ m_Instance

Self* itk::SingletonIndex::m_Instance
staticprivate

Definition at line 128 of file itkSingleton.h.


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