#include <PopConSourceHandler.h>
Public Member Functions | |
T const & | operator* () const |
T const * | operator-> () const |
Ref & | operator= (const Ref &ref) |
T const * | ptr () const |
Ref (cond::DbSession &dbsession, std::string token) | |
Ref () | |
Ref (const Ref &ref) | |
~Ref () | |
Private Attributes | |
boost::shared_ptr< T > | m_d |
cond::DbSession | m_dbsession |
Definition at line 53 of file PopConSourceHandler.h.
popcon::PopConSourceHandler< T >::Ref::Ref | ( | ) | [inline] |
Definition at line 55 of file PopConSourceHandler.h.
: m_dbsession(){}
popcon::PopConSourceHandler< T >::Ref::Ref | ( | cond::DbSession & | dbsession, |
std::string | token | ||
) | [inline] |
Definition at line 56 of file PopConSourceHandler.h.
References cond::DbSession::getTypedObject(), popcon::PopConSourceHandler< T >::Ref::m_d, popcon::PopConSourceHandler< T >::Ref::m_dbsession, and cond::DbSession::transaction().
: m_dbsession(dbsession){ m_dbsession.transaction().start(true); m_d = m_dbsession.getTypedObject<T>(token); }
popcon::PopConSourceHandler< T >::Ref::~Ref | ( | ) | [inline] |
Definition at line 61 of file PopConSourceHandler.h.
References cond::DbSession::isOpen(), popcon::PopConSourceHandler< T >::Ref::m_dbsession, and cond::DbSession::transaction().
{ if(m_dbsession.isOpen()) m_dbsession.transaction().commit(); }
popcon::PopConSourceHandler< T >::Ref::Ref | ( | const Ref & | ref | ) | [inline] |
Definition at line 66 of file PopConSourceHandler.h.
: m_dbsession(ref.m_dbsession), m_d(ref.m_d) { //ref.m_dbsession=0; // avoid commit; }
T const& popcon::PopConSourceHandler< T >::Ref::operator* | ( | ) | const [inline] |
Definition at line 86 of file PopConSourceHandler.h.
References popcon::PopConSourceHandler< T >::Ref::ptr().
{ return *ptr(); }
T const* popcon::PopConSourceHandler< T >::Ref::operator-> | ( | ) | const [inline] |
Definition at line 82 of file PopConSourceHandler.h.
References popcon::PopConSourceHandler< T >::Ref::ptr().
{ return ptr(); }
Ref& popcon::PopConSourceHandler< T >::Ref::operator= | ( | const Ref & | ref | ) | [inline] |
Definition at line 71 of file PopConSourceHandler.h.
References popcon::PopConSourceHandler< T >::Ref::m_d, and popcon::PopConSourceHandler< T >::Ref::m_dbsession.
{ m_dbsession = ref.m_dbsession; m_d = ref.m_d; //ref.m_dbsession=0; // avoid commit; return *this; }
T const* popcon::PopConSourceHandler< T >::Ref::ptr | ( | ) | const [inline] |
Definition at line 78 of file PopConSourceHandler.h.
References popcon::PopConSourceHandler< T >::Ref::m_d.
Referenced by popcon::PopConSourceHandler< T >::Ref::operator*(), and popcon::PopConSourceHandler< T >::Ref::operator->().
{ return m_d.get(); }
boost::shared_ptr<T> popcon::PopConSourceHandler< T >::Ref::m_d [private] |
Definition at line 94 of file PopConSourceHandler.h.
Referenced by popcon::PopConSourceHandler< T >::Ref::operator=(), popcon::PopConSourceHandler< T >::Ref::ptr(), and popcon::PopConSourceHandler< T >::Ref::Ref().
cond::DbSession popcon::PopConSourceHandler< T >::Ref::m_dbsession [private] |
Definition at line 93 of file PopConSourceHandler.h.
Referenced by popcon::PopConSourceHandler< T >::Ref::operator=(), popcon::PopConSourceHandler< T >::Ref::Ref(), and popcon::PopConSourceHandler< T >::Ref::~Ref().