9 #ifndef _QI_TRACKABLE_HPP_
10 #define _QI_TRACKABLE_HPP_
12 #include <boost/thread/mutex.hpp>
13 #include <boost/shared_ptr.hpp>
14 #include <boost/thread/condition_variable.hpp>
15 #include <boost/function.hpp>
49 boost::shared_ptr<T>
lock();
69 boost::shared_ptr<T> _ptr;
70 boost::condition_variable _cond;
78 virtual const char*
what()
const throw()
80 return "Pointer Lock failed";
90 template<
typename RF,
typename AF> boost::function<RF>
bind(
const AF& fun, ...);
99 template<
typename F,
typename ARG0>
100 boost::function<F>
track(
const boost::function<F>& f,
const ARG0& arg0);
101 template<
typename F,
typename ARG0>
103 const boost::function<F>& f,
const ARG0& arg0);
107 #endif // _QI_TRACKABLE_HPP_
boost::weak_ptr< T > weakPtr()
boost::shared_ptr< T > lock()
boost::function< F > trackWithFallback(boost::function< void()> onFail, const boost::function< F > &f, const ARG0 &arg0)
boost::function< RF > bind(const AF &fun,...)
Common base class to templates Trackable for compile-time detection.
boost::function< F > track(const boost::function< F > &f, const ARG0 &arg0)
virtual const char * what() const