FreeNOS
|
Singleton design pattern: only one instance is allowed. More...
#include <Singleton.h>
Static Public Member Functions | |
static T * | instance () |
Retrieve the instance. More... | |
Singleton design pattern: only one instance is allowed.
The StrictSingleton has the following constraints:
Definition at line 39 of file Singleton.h.
|
inlinestatic |
Retrieve the instance.
Note that we use a static initializer here, which makes use of the __cxa_guard_acquire and __cxa_guard_release functions in order to guarantee the object is only initialized once.
Definition at line 53 of file Singleton.h.