toast/singleton.hpp File Reference


Detailed Description

singleton.hpp contains the singleton_helper template class.

#include <sstream>
#include <boost/thread/mutex.hpp>
#include <boost/thread/tss.hpp>
#include <boost/optional.hpp>
#include <boost/none.hpp>
#include <boost/mpl/bool.hpp>
#include <toast/assert.hpp>
#include <toast/typeinfo.hpp>
#include <toast/typed_factory.hpp>
#include <toast/async/lockable.hpp>
#include <boost/utility/enable_if.hpp>
#include <boost/type_traits/is_same.hpp>
#include <toast/static_init_protected.hpp>

Go to the source code of this file.

Namespaces

namespace  toast
namespace  toast::detail

Classes

class  toast::detail::holder< T, T >
class  toast::detail::sync_helper< T, U >
class  toast::detail::holder< T, boost::optional< T > >
class  toast::detail::holder< T, T * >
class  toast::detail::holder< T, boost::thread_specific_ptr< T > >
struct  toast::default_factory< T >
 This factory creates T with its default constructor. More...
class  toast::global_factory< T >
 This factory creates T with any toast::typed_factory<T> you like. More...
class  toast::thread_specific_factory< T >
 This factory creates T with any toast::typed_factory<T> you like. More...
class  toast::singleton_helper< T, HolderType, FactoryType, Enable >
 This helper deals with all the accounting details of properly managing a singleton. More...
class  toast::singleton_helper< T, boost::optional< T >, thread_specific_factory< T > >
class  toast::singleton_helper< T, T *, thread_specific_factory< T > >
class  toast::singleton_helper< T, T, U, typename boost::template disable_if< boost::is_same< U, default_factory< T > > >::type >

Functions

template<typename T>
std::string toast::detail::no_factory ()
template<typename T>
std::string toast::detail::factory_already_exists ()


SourceForge.net Logo