1 #ifndef BOOSTER_INTRUSIVE_PTR_H_INCLUDED 2 #define BOOSTER_INTRUSIVE_PTR_H_INCLUDED 50 typedef T element_type;
58 if(p_ != 0 && add_ref) intrusive_ptr_add_ref(p_);
70 if(p_ != 0) intrusive_ptr_add_ref(p_);
75 if(p_ != 0) intrusive_ptr_release(p_);
80 if(p_ != 0) intrusive_ptr_add_ref(p_);
85 this_type(rhs).swap(*
this);
91 this_type(rhs).swap(*
this);
100 T & operator*()
const 105 T * operator->()
const 111 typedef T * this_type::*unspecified_bool_type;
113 operator unspecified_bool_type ()
const 115 return p_ == 0? 0: &this_type::p_;
119 bool operator! ()
const 138 return a.get() == b.get();
143 return a.get() != b.get();
166 template<
class T>
inline bool operator<(intrusive_ptr<T>
const & a,
intrusive_ptr<T> const & b)
168 return std::less<T *>()(a.get(), b.get());
185 return static_cast<T *
>(p.get());
190 return const_cast<T *
>(p.get());
195 return dynamic_cast<T *
>(p.get());
201 template<
class E,
class T,
class Y>
202 std::basic_ostream<E, T> & operator<< (std::basic_ostream<E, T> & os,
intrusive_ptr<Y> const & p)
211 #endif // #ifndef BOOSTER_INTRUSIVE_PTR_H_INCLUDED intrusive_ptr is the class taken as-is from boost.
Definition: intrusive_ptr.h:42
Booster library namespace. The library that implements Boost Like API in ABI backward compatible way...
Definition: application.h:23