RAI thread
wrapper adding a specific destroyer allowing to master what can be done at destruction time.
More...
#include <scoped_thread.hpp>
Public Member Functions | |
BOOST_THREAD_NO_COPYABLE (strict_scoped_thread) template< class F | |
non copyable More... | |
RAI thread
wrapper adding a specific destroyer allowing to master what can be done at destruction time.
CallableThread: A callable void(thread&) . The default is a join_if_joinable.
thread std/boost::thread destructor terminates the program if the thread is not joinable. Having a wrapper that can join the thread before destroying it seems a natural need.
Example:
boost::strict_scoped_thread<> t((boost::thread(F)));
boost::strict_scoped_thread< CallableThread >::BOOST_THREAD_NO_COPYABLE | ( | strict_scoped_thread< CallableThread > | ) |
non copyable