#include <FEConfigPedInfo.h>
Definition at line 11 of file FEConfigPedInfo.h.
FEConfigPedInfo::FEConfigPedInfo |
( |
| ) |
|
Definition at line 13 of file FEConfigPedInfo.cc.
References clear().
oracle::occi::Environment * m_env
oracle::occi::Connection * m_conn
FEConfigPedInfo::~FEConfigPedInfo |
( |
| ) |
|
|
override |
void FEConfigPedInfo::clear |
( |
void |
| ) |
|
|
private |
Definition at line 105 of file FEConfigPedInfo.cc.
References DateHandler::dateToTm(), cuy::dh, alignCSCRings::e, mps_fire::result, and AlCaHLTBitMon_QueryRunRegistry::string.
109 throw(std::runtime_error(
"FEConfigPedInfo::fetchData(): no Id defined for this FEConfigPedInfo "));
115 m_readStmt->setSQL(
"SELECT * FROM " +
getTable() +
" where ( ped_conf_id= :1 or (tag=:2 AND version=:3 ) )");
125 result->
setId(rset->getInt(1));
129 Date dbdate = rset->getDate(5);
133 throw(std::runtime_error(
std::string(
"FEConfigPedInfo::fetchData(): ") + e.getMessage()));
oracle::occi::Environment * m_env
oracle::occi::Connection * m_conn
void setDBTime(const Tm &x)
void checkConnection() const noexcept(false)
void setIOVId(int iov_id)
void setConfigTag(std::string x)
oracle::occi::SQLException SQLException
std::string getConfigTag()
std::string getTable() override
int FEConfigPedInfo::fetchID |
( |
| ) |
|
|
noexcept |
Definition at line 161 of file FEConfigPedInfo.cc.
References alignCSCRings::e, and AlCaHLTBitMon_QueryRunRegistry::string.
171 stmt->setSQL(
"SELECT ped_conf_id FROM " +
getTable() +
" WHERE tag=:1 and version=:2 ");
176 ResultSet* rset = stmt->executeQuery();
179 m_ID = rset->getInt(1);
183 m_conn->terminateStatement(stmt);
185 throw(std::runtime_error(
std::string(
"FEConfigPedInfo::fetchID: ") + e.getMessage()));
oracle::occi::Connection * m_conn
void checkConnection() const noexcept(false)
oracle::occi::Statement Statement
oracle::occi::SQLException SQLException
std::string getConfigTag()
std::string getTable() override
int FEConfigPedInfo::fetchNextId |
( |
| ) |
|
|
noexcept |
Tm FEConfigPedInfo::getDBTime |
( |
| ) |
const |
|
inline |
int FEConfigPedInfo::getId |
( |
void |
| ) |
const |
|
inline |
int FEConfigPedInfo::getID |
( |
| ) |
|
|
inline |
int FEConfigPedInfo::getIOVId |
( |
| ) |
const |
|
inline |
std::string FEConfigPedInfo::getTable |
( |
| ) |
|
|
inlineoverridevirtual |
int FEConfigPedInfo::getVersion |
( |
| ) |
const |
|
inline |
void FEConfigPedInfo::prepareWrite |
( |
| ) |
|
|
overrideprivatevirtualnoexcept |
Implements IODConfig.
Definition at line 48 of file FEConfigPedInfo.cc.
References alignCSCRings::e, getId(), and AlCaHLTBitMon_QueryRunRegistry::string.
59 " ( ped_conf_id, tag, version, iov_id) "
60 " VALUES ( :1, :2, :3 , :4) ");
66 throw(std::runtime_error(
std::string(
"FEConfigPedInfo::prepareWrite(): ") + e.getMessage()));
oracle::occi::Connection * m_conn
void checkConnection() const noexcept(false)
oracle::occi::SQLException SQLException
int fetchNextId() noexcept(false)
std::string getTable() override
void FEConfigPedInfo::setByID |
( |
int |
id | ) |
|
|
noexcept |
Definition at line 191 of file FEConfigPedInfo.cc.
References DateHandler::dateToTm(), cuy::dh, alignCSCRings::e, and AlCaHLTBitMon_QueryRunRegistry::string.
199 stmt->setSQL(
"SELECT * FROM fe_config_ped_info WHERE ped_conf_id = :1");
202 ResultSet* rset = stmt->executeQuery();
204 this->
setId(rset->getInt(1));
208 Date dbdate = rset->getDate(5);
211 throw(std::runtime_error(
"FEConfigPedInfo::setByID: Given config_id is not in the database"));
214 m_conn->terminateStatement(stmt);
216 throw(std::runtime_error(
std::string(
"FEConfigPedInfo::setByID: ") + e.getMessage()));
oracle::occi::Environment * m_env
oracle::occi::Connection * m_conn
void setDBTime(const Tm &x)
void checkConnection() const noexcept(false)
void setIOVId(int iov_id)
oracle::occi::Statement Statement
void setConfigTag(std::string x)
oracle::occi::SQLException SQLException
void FEConfigPedInfo::setDBTime |
( |
const Tm & |
x | ) |
|
|
inline |
void FEConfigPedInfo::setId |
( |
int |
id | ) |
|
|
inline |
void FEConfigPedInfo::setID |
( |
int |
id | ) |
|
|
inline |
void FEConfigPedInfo::setIOVId |
( |
int |
iov_id | ) |
|
|
inline |
void FEConfigPedInfo::setParameters |
( |
const std::map< std::string, std::string > & |
my_keys_map | ) |
|
Definition at line 70 of file FEConfigPedInfo.cc.
74 for (std::map<std::string, std::string>::const_iterator ci = my_keys_map.begin(); ci != my_keys_map.end(); ci++) {
75 if (ci->first ==
"VERSION")
77 if (ci->first ==
"TAG")
79 if (ci->first ==
"IOV_ID")
void setIOVId(int iov_id)
void setConfigTag(std::string x)
void FEConfigPedInfo::setVersion |
( |
int |
id | ) |
|
|
inline |
void FEConfigPedInfo::writeDB |
( |
| ) |
|
|
privatenoexcept |
Definition at line 84 of file FEConfigPedInfo.cc.
References alignCSCRings::e, and AlCaHLTBitMon_QueryRunRegistry::string.
97 throw(std::runtime_error(
std::string(
"FEConfigPedInfo::writeDB(): ") + e.getMessage()));
101 throw(std::runtime_error(
"FEConfigPedInfo::writeDB: Failed to write"));
void checkConnection() const noexcept(false)
oracle::occi::SQLException SQLException
std::string getConfigTag()
int fetchID() noexcept(false)
void checkPrepare() noexcept(false)
Tm FEConfigPedInfo::m_db_time |
|
private |
int FEConfigPedInfo::m_ID |
|
private |
int FEConfigPedInfo::m_iov_id |
|
private |
int FEConfigPedInfo::m_version |
|
private |