|
SUNphi
1.0
|
#include <SingleInstance.hpp>
Public Member Functions | |
| SingleInstance () | |
| Constructor, checking no instance exists before. | |
| ~SingleInstance () | |
| Destructor, checking that no instance exists at the end. | |
Private Member Functions | |
| void | crashIfInstancesExists () |
| Check that no instance exists. | |
Static Private Member Functions | |
| static int & | count () |
Single Instance enforcer class
To enforce a class to be instantiated at most once, inherit this class. Example:
Definition at line 29 of file SingleInstance.hpp.
|
inlinestaticprivate |