CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
cond::persistency::IOVCache Class Reference

#include <OraDbSchema.h>

Public Member Functions

void addTag (const std::string &tag, const std::string token)
 
cond::IOVEditor editor ()
 
bool existsTag (const std::string &tag)
 
std::string getToken (const std::string &tag)
 
 IOVCache (cond::DbSession &s)
 
cond::IOVProxy iovSequence ()
 
bool load (const std::string &tag)
 
cond::DbSessionsession ()
 
void setValidationMode ()
 
bool validationMode ()
 

Private Attributes

cond::IOVEditor m_iovAccess
 
std::string m_tag
 
std::string m_token
 
bool m_validationMode = false
 

Detailed Description

Definition at line 18 of file OraDbSchema.h.

Constructor & Destructor Documentation

cond::persistency::IOVCache::IOVCache ( cond::DbSession s)

Definition at line 17 of file OraDbSchema.cc.

17  :
18  m_iovAccess( s ){
19  }
cond::IOVEditor m_iovAccess
Definition: OraDbSchema.h:35

Member Function Documentation

void cond::persistency::IOVCache::addTag ( const std::string &  tag,
const std::string  token 
)

Definition at line 47 of file OraDbSchema.cc.

References cond::MetaData::addMapping(), m_tag, m_token, session(), and GlobalPosition_Frontier_DevDB_cff::tag.

Referenced by cond::persistency::OraTagTable::insert().

47  {
48  if( tag != m_tag ){
49  cond::MetaData metadata( session() );
50  metadata.addMapping( tag, token );
51  m_tag = tag;
52  m_token = token;
53  }
54  }
cond::DbSession & session()
Definition: OraDbSchema.cc:21
cond::IOVEditor cond::persistency::IOVCache::editor ( )
bool cond::persistency::IOVCache::existsTag ( const std::string &  tag)

Definition at line 33 of file OraDbSchema.cc.

References cond::MetaData::hasTag(), and session().

Referenced by cond::persistency::OraTagTable::select().

33  {
34  cond::MetaData metadata( session() );
35  return metadata.hasTag( t );
36  }
tuple t
Definition: tree.py:139
cond::DbSession & session()
Definition: OraDbSchema.cc:21
std::string cond::persistency::IOVCache::getToken ( const std::string &  tag)

Definition at line 38 of file OraDbSchema.cc.

References cond::MetaData::getToken(), m_tag, m_token, session(), and GlobalPosition_Frontier_DevDB_cff::tag.

Referenced by load(), and cond::persistency::OraTagTable::update().

38  {
39  if( tag != m_tag ){
40  cond::MetaData metadata( session() );
41  m_tag = tag;
42  m_token = metadata.getToken( tag );
43  }
44  return m_token;
45  }
cond::DbSession & session()
Definition: OraDbSchema.cc:21
cond::IOVProxy cond::persistency::IOVCache::iovSequence ( )
bool cond::persistency::IOVCache::load ( const std::string &  tag)
cond::DbSession & cond::persistency::IOVCache::session ( )
void cond::persistency::IOVCache::setValidationMode ( )
inline

Definition at line 28 of file OraDbSchema.h.

References m_validationMode.

Referenced by cond::persistency::OraTagTable::setValidationMode().

28  {
29  m_validationMode = true;
30  }
bool cond::persistency::IOVCache::validationMode ( )
inline

Definition at line 31 of file OraDbSchema.h.

References m_validationMode.

Referenced by cond::persistency::OraTagTable::insert(), and cond::persistency::OraTagTable::update().

31  {
32  return m_validationMode;
33  }

Member Data Documentation

cond::IOVEditor cond::persistency::IOVCache::m_iovAccess
private

Definition at line 35 of file OraDbSchema.h.

Referenced by editor(), iovSequence(), load(), and session().

std::string cond::persistency::IOVCache::m_tag
private

Definition at line 36 of file OraDbSchema.h.

Referenced by addTag(), and getToken().

std::string cond::persistency::IOVCache::m_token
private

Definition at line 37 of file OraDbSchema.h.

Referenced by addTag(), and getToken().

bool cond::persistency::IOVCache::m_validationMode = false
private

Definition at line 38 of file OraDbSchema.h.

Referenced by setValidationMode(), and validationMode().