#include <Handle.h>
Public Member Functions | |
void | clear () |
T * | get () const |
Handle () | |
Handle (T *ptr) | |
Handle (const Handle< T > &rhs) | |
operator bool () const | |
bool | operator! () const |
T & | operator* () const |
T * | operator-> () const |
Handle & | operator= (const Handle< T > &rhs) |
void | reset (T *ptr) |
~Handle () | |
Private Member Functions | |
void | validate () const |
Private Attributes | |
boost::shared_ptr< Holder< T > > | m_holder |
Handle::Handle | ( | ) | [inline] |
Handle::Handle | ( | T * | ptr | ) | [inline, explicit] |
void Handle::clear | ( | void | ) | [inline] |
T * Handle::get | ( | void | ) | const [inline] |
Definition at line 147 of file Handle.h.
Referenced by ora::Handle< T >::operator bool(), and ora::Handle< T >::operator!().
{ return m_holder->ptr.get(); }
Handle::operator bool | ( | ) | const [inline] |
Definition at line 135 of file Handle.h.
References ora::Handle< T >::get().
{ return m_holder->ptr.get()!=0; }
bool Handle::operator! | ( | ) | const [inline] |
Definition at line 141 of file Handle.h.
References ora::Handle< T >::get().
{ return m_holder->ptr.get()==0; }
T & Handle::operator* | ( | ) | const [inline] |
T * Handle::operator-> | ( | ) | const [inline] |
ora::Handle< T > & Handle::operator= | ( | const Handle< T > & | rhs | ) | [inline] |
Definition at line 100 of file Handle.h.
References ora::Handle< T >::m_holder.
{ m_holder = rhs.m_holder; return *this; }
void Handle::reset | ( | T * | ptr | ) | [inline] |
Definition at line 107 of file Handle.h.
Referenced by ora::DatabaseContainer::iteratorBuffer().
{ m_holder.reset( new Holder<T>( ptr ) ); }
void Handle::validate | ( | ) | const [inline, private] |
Definition at line 113 of file Handle.h.
References ora::throwException().
{ if(!m_holder->ptr.get()) { throwException( "Handle is not valid.",typeid(Handle<T>),"validate"); } }
boost::shared_ptr< Holder<T> > ora::Handle< T >::m_holder [private] |
Definition at line 54 of file Handle.h.
Referenced by ora::Handle< T >::operator=().