#include <FEConfigTimingDat.h>
Definition at line 11 of file FEConfigTimingDat.h.
FEConfigTimingDat::FEConfigTimingDat |
( |
| ) |
|
Definition at line 11 of file FEConfigTimingDat.cc.
References NULL.
oracle::occi::Environment * m_env
oracle::occi::Statement * m_writeStmt
oracle::occi::Connection * m_conn
oracle::occi::Statement * m_readStmt
FEConfigTimingDat::~FEConfigTimingDat |
( |
| ) |
|
Definition at line 72 of file FEConfigTimingDat.cc.
References MillePedeFileConverter_cfg::e, AlCaHLTBitMon_ParallelJobs::p, setTimingPar1(), and setTimingPar2().
Referenced by getTimingPar2().
86 m_readStmt->setSQL(
"SELECT cv.name, cv.logic_id, cv.id1, cv.id2, cv.id3, cv.maps_to, " 87 "d.time_par1, d.time_par2 " 88 "FROM channelview cv JOIN " +
getTable() +
" d ON cv.logic_id = d.logic_id AND cv.name = cv.maps_to " 89 "WHERE tim_conf_id = :tim_conf_id");
93 std::pair< EcalLogicID, FEConfigTimingDat >
p;
109 }
catch (SQLException &
e) {
110 throw(std::runtime_error(
"FEConfigTimingDat::fetchData: "+e.getMessage()));
oracle::occi::Environment * m_env
oracle::occi::Connection * m_conn
void setTimingPar2(int x)
void checkConnection() const noexcept(false)
void setTimingPar1(int x)
oracle::occi::Statement * m_readStmt
int fetchID() noexcept(false)
void setConnection(oracle::occi::Environment *env, oracle::occi::Connection *conn)
std::string FEConfigTimingDat::getTable |
( |
| ) |
|
|
inlinevirtual |
int FEConfigTimingDat::getTimingPar1 |
( |
| ) |
const |
|
inline |
int FEConfigTimingDat::getTimingPar2 |
( |
| ) |
const |
|
inline |
void FEConfigTimingDat::prepareWrite |
( |
| ) |
|
|
privatevirtualnoexcept |
Implements IDataItem.
Definition at line 31 of file FEConfigTimingDat.cc.
References MillePedeFileConverter_cfg::e.
Referenced by getTimingPar2().
39 "time_par1, time_par2 ) VALUES (:tim_conf_id, :logic_id, :time_par1, :time_par2 )" );
40 }
catch (SQLException &
e) {
41 throw(std::runtime_error(
"FEConfigTimingDat::prepareWrite(): "+e.getMessage()));
oracle::occi::Statement * m_writeStmt
oracle::occi::Connection * m_conn
void checkConnection() const noexcept(false)
void FEConfigTimingDat::setTimingPar1 |
( |
int |
x | ) |
|
|
inline |
void FEConfigTimingDat::setTimingPar2 |
( |
int |
x | ) |
|
|
inline |
Definition at line 114 of file FEConfigTimingDat.cc.
References KineDebug3::count(), data, MillePedeFileConverter_cfg::e, EcalLogicID::getLogicID(), getTimingPar1(), getTimingPar2(), AlCaHLTBitMon_ParallelJobs::p, x, geometryCSVtoXML::xx, y, and geometryCSVtoXML::yy.
Referenced by getTimingPar2().
120 int iconfID = iconf->
fetchID();
121 if (!iconfID) {
throw(std::runtime_error(
"FEConfigTimingDat::writeArrayDB: tim_conf_id not in DB")); }
124 int nrows=
data->size();
125 int* ids=
new int[nrows];
126 int* iconfid_vec=
new int[nrows];
127 int*
xx=
new int[nrows];
128 int*
yy=
new int[nrows];
130 ub2* ids_len=
new ub2[nrows];
131 ub2* iconf_len=
new ub2[nrows];
132 ub2* x_len=
new ub2[nrows];
133 ub2* y_len=
new ub2[nrows];
138 typedef map< EcalLogicID, FEConfigTimingDat >::const_iterator CI;
139 for (CI
p =
data->begin();
p !=
data->end(); ++
p) {
140 channel = &(
p->first);
142 if (!logicID) {
throw(std::runtime_error(
"FEConfigTimingDat::writeArrayDB: Bad EcalLogicID")); }
144 iconfid_vec[
count]=iconfID;
146 dataitem = &(
p->second);
165 m_writeStmt->setDataBuffer(1, (dvoid*)iconfid_vec, OCCIINT,
sizeof(iconfid_vec[0]),iconf_len);
166 m_writeStmt->setDataBuffer(2, (dvoid*)ids, OCCIINT,
sizeof(ids[0]), ids_len );
167 m_writeStmt->setDataBuffer(3, (dvoid*)xx, OCCIINT ,
sizeof(xx[0]), x_len );
168 m_writeStmt->setDataBuffer(4, (dvoid*)yy, OCCIINT ,
sizeof(yy[0]), y_len );
173 delete [] iconfid_vec;
182 }
catch (SQLException &
e) {
183 throw(std::runtime_error(
"FEConfigTimingDat::writeArrayDB(): "+e.getMessage()));
oracle::occi::Statement * m_writeStmt
void checkPrepare() noexcept(false)
void checkConnection() const noexcept(false)
int getTimingPar2() const
int getTimingPar1() const
int fetchID() noexcept(false)
char data[epos_bytes_allocation]
Definition at line 46 of file FEConfigTimingDat.cc.
References MillePedeFileConverter_cfg::e.
Referenced by getTimingPar2().
53 if (!iconfID) {
throw(std::runtime_error(
"FEConfigTimingDat::writeDB: ICONF not in DB")); }
56 if (!logicID) {
throw(std::runtime_error(
"FEConfigTimingDat::writeDB: Bad EcalLogicID")); }
65 }
catch (SQLException &
e) {
66 throw(std::runtime_error(
"FEConfigTimingDat::writeDB(): "+e.getMessage()));
oracle::occi::Statement * m_writeStmt
void checkPrepare() noexcept(false)
void checkConnection() const noexcept(false)
int getTimingPar2() const
int getTimingPar1() const
int fetchID() noexcept(false)
int FEConfigTimingDat::m_par1 |
|
private |
int FEConfigTimingDat::m_par2 |
|
private |