#include <toast/singleton.hpp>
If you can't use toast::default_factory<T>, and you're not using a HolderType of boost::thread_specific_ptr<T> then this is the right factory for you. If you're using the boost::thread_specific_ptr<T> and you want only a single factory to create the instance on each thread, this is still the factory for you. If you'd like a different factory per thread use the toast::thread_specific_factory<T>.
Static Public Member Functions | |
static void | set (typed_factory< T > const &f) |
static typed_factory< T > | get () |