20#ifndef PALUDIS_GUARD_PALUDIS_SINGLETON_HH
21#define PALUDIS_GUARD_PALUDIS_SINGLETON_HH 1
43 template <
typename OurType_>
47 static OurType_ * * _get_instance_ptr();
49 class DeleteOnDestruction;
50 friend class DeleteOnDestruction;
52 static void _delete(OurType_ *
const p);
58 Singleton() =
default;
59 Singleton(
const Singleton &) =
delete;
60 const Singleton & operator= (
const Singleton &) =
delete;
static void destroy_instance()
static OurType_ * get_instance() PALUDIS_ATTRIBUTE((warn_unused_result))
#define PALUDIS_ATTRIBUTE(x)
Definition attributes.hh:53
#define PALUDIS_VISIBLE
Definition attributes.hh:59
Definition about_metadata-fwd.hh:24