#include <MODDCCOperationDat.h>
Definition at line 11 of file MODDCCOperationDat.h.
MODDCCOperationDat::MODDCCOperationDat |
( |
| ) |
|
Definition at line 11 of file MODDCCOperationDat.cc.
oracle::occi::Environment * m_env
oracle::occi::Statement * m_writeStmt
oracle::occi::Connection * m_conn
oracle::occi::Statement * m_readStmt
MODDCCOperationDat::~MODDCCOperationDat |
( |
| ) |
|
|
override |
Definition at line 72 of file MODDCCOperationDat.cc.
References MillePedeFileConverter_cfg::e, AlCaHLTBitMon_ParallelJobs::p, setOperation(), and AlCaHLTBitMon_QueryRunRegistry::string.
Referenced by getOperation().
87 m_readStmt->setSQL(
"SELECT cv.name, cv.logic_id, cv.id1, cv.id2, cv.id3, cv.maps_to, " 89 "FROM channelview cv JOIN "+
getTable()+
" d " 90 "ON cv.logic_id = d.logic_id AND cv.name = cv.maps_to " 91 "WHERE d.iov_id = :iov_id");
95 std::pair< EcalLogicID, MODDCCOperationDat >
p;
103 getOraString(rset,6));
110 }
catch (SQLException &
e) {
111 throw(std::runtime_error(
std::string(
"MODDCCOperationDat::fetchData(): ")+getOraMessage(&e)));
oracle::occi::Environment * m_env
oracle::occi::Connection * m_conn
void checkConnection() const noexcept(false)
int fetchID() noexcept(false) override
oracle::occi::Statement * m_readStmt
std::string getTable() override
void setConnection(oracle::occi::Environment *env, oracle::occi::Connection *conn)
void setOperation(std::string x)
std::string MODDCCOperationDat::getOperation |
( |
| ) |
const |
|
inline |
std::string MODDCCOperationDat::getTable |
( |
| ) |
|
|
inlineoverridevirtual |
void MODDCCOperationDat::prepareWrite |
( |
| ) |
|
|
overrideprivatevirtualnoexcept |
void MODDCCOperationDat::setOperation |
( |
std::string |
x | ) |
|
|
inline |
Definition at line 115 of file MODDCCOperationDat.cc.
References KineDebug3::count(), data, MillePedeFileConverter_cfg::e, EcalLogicID::getLogicID(), getOperation(), AlCaHLTBitMon_ParallelJobs::p, AlCaHLTBitMon_QueryRunRegistry::string, x, and geometryCSVtoXML::xx.
Referenced by getOperation().
122 if (!iovID) {
throw(std::runtime_error(
"MODDCCOperationDat::writeArrayDB: IOV not in DB")); }
125 int nrows=
data->size();
126 int* ids=
new int[nrows];
127 int* iovid_vec=
new int[nrows];
130 ub2* ids_len=
new ub2[nrows];
131 ub2* iov_len=
new ub2[nrows];
132 ub2* x_len=
new ub2[nrows];
137 typedef map< EcalLogicID, MODDCCOperationDat >::const_iterator CI;
138 for (CI
p =
data->begin();
p !=
data->end(); ++
p) {
139 channel = &(
p->first);
141 if (!logicID) {
throw(std::runtime_error(
"MODDCCOperationDat::writeArrayDB: Bad EcalLogicID")); }
143 iovid_vec[
count]=iovID;
145 dataitem = &(
p->second);
161 m_writeStmt->setDataBuffer(1, (dvoid*)iovid_vec, OCCIINT,
sizeof(iovid_vec[0]),iov_len);
162 m_writeStmt->setDataBuffer(2, (dvoid*)ids, OCCIINT,
sizeof(ids[0]), ids_len );
163 m_writeStmt->setDataBuffer(3, (dvoid*)xx, OCCISTRING ,
sizeof(xx[0]), x_len );
178 }
catch (SQLException &
e) {
179 throw(std::runtime_error(
std::string(
"MonPedestalsDat::writeArrayDB(): ")+getOraMessage(&e)));
std::string getOperation() const
oracle::occi::Statement * m_writeStmt
void checkPrepare() noexcept(false)
void checkConnection() const noexcept(false)
int fetchID() noexcept(false) override
char data[epos_bytes_allocation]
Definition at line 47 of file MODDCCOperationDat.cc.
References MillePedeFileConverter_cfg::e, and AlCaHLTBitMon_QueryRunRegistry::string.
Referenced by getOperation().
54 if (!iovID) {
throw(std::runtime_error(
"MODDCCOperationDat::writeDB: IOV not in DB")); }
57 if (!logicID) {
throw(std::runtime_error(
"MODDCCOperationDat::writeDB: Bad EcalLogicID")); }
65 }
catch (SQLException &
e) {
66 throw(std::runtime_error(
std::string(
"MODDCCOperationDat::writeDB(): ")+getOraMessage(&e)));
std::string getOperation() const
oracle::occi::Statement * m_writeStmt
void checkPrepare() noexcept(false)
void checkConnection() const noexcept(false)
int fetchID() noexcept(false) override
std::string MODDCCOperationDat::m_word |
|
private |