13 #ifndef STXXL_SINGLETON_HEADER
14 #define STXXL_SINGLETON_HEADER
26 template <
typename INSTANCE,
bool destroy_on_exit = true>
36 static void destroy_instance();
42 return create_instance();
48 template <
typename INSTANCE,
bool destroy_on_exit>
49 typename singleton<INSTANCE, destroy_on_exit>::instance_pointer
52 static mutex create_mutex;
62 template <
typename INSTANCE,
bool destroy_on_exit>
71 template <
typename INSTANCE,
bool destroy_on_exit>
77 #endif // !STXXL_SINGLETON_HEADER
Encapsulates disk queues.
instance_type * instance_pointer
static instance_pointer get_instance()
Aquire a lock that's valid until the end of scope.
#define STXXL_BEGIN_NAMESPACE
choose_int_types< my_pointer_size >::unsigned_type unsigned_type
int register_exit_handler(void(*function)(void))
volatile instance_pointer volatile_instance_pointer
static volatile_instance_pointer instance
#define STXXL_END_NAMESPACE