#include <MonH4TablePositionDat.h>
Definition at line 11 of file MonH4TablePositionDat.h.
◆ MonH4TablePositionDat()
MonH4TablePositionDat::MonH4TablePositionDat |
( |
| ) |
|
◆ ~MonH4TablePositionDat()
MonH4TablePositionDat::~MonH4TablePositionDat |
( |
| ) |
|
|
override |
◆ fetchData()
Definition at line 66 of file MonH4TablePositionDat.cc.
80 "SELECT cv.name, cv.logic_id, cv.id1, cv.id2, cv.id3, cv.maps_to, "
81 "d.table_x, d.table_y "
82 "FROM channelview cv JOIN mon_h4_table_position_dat d "
83 "ON cv.logic_id = d.logic_id AND cv.name = cv.maps_to "
84 "WHERE d.iov_id = :iov_id");
88 std::pair<EcalLogicID, MonH4TablePositionDat>
p;
90 while (rset->next()) {
104 }
catch (SQLException&
e) {
105 throw(std::runtime_error(
"MonH4TablePositionDat::fetchData(): " +
e.getMessage()));
References MillePedeFileConverter_cfg::e, AlCaHLTBitMon_ParallelJobs::p, setTableX(), and setTableY().
◆ getTable()
std::string MonH4TablePositionDat::getTable |
( |
| ) |
|
|
inlineoverridevirtual |
◆ getTableX()
float MonH4TablePositionDat::getTableX |
( |
| ) |
const |
|
inline |
◆ getTableY()
float MonH4TablePositionDat::getTableY |
( |
| ) |
const |
|
inline |
◆ prepareWrite()
void MonH4TablePositionDat::prepareWrite |
( |
| ) |
|
|
overrideprivatevirtualnoexcept |
Implements IDataItem.
Definition at line 22 of file MonH4TablePositionDat.cc.
28 "INSERT INTO mon_h4_table_position_dat (iov_id, logic_id, "
30 "VALUES (:iov_id, :logic_id, "
32 }
catch (SQLException&
e) {
33 throw(std::runtime_error(
"MonH4TablePositionDat::prepareWrite(): " +
e.getMessage()));
References MillePedeFileConverter_cfg::e.
◆ setTableX()
void MonH4TablePositionDat::setTableX |
( |
float |
x | ) |
|
|
inline |
◆ setTableY()
void MonH4TablePositionDat::setTableY |
( |
float |
y | ) |
|
|
inline |
◆ writeArrayDB()
Definition at line 109 of file MonH4TablePositionDat.cc.
116 throw(std::runtime_error(
"MonH4TablePositionDat::writeArrayDB: IOV not in DB"));
119 int nrows =
data->size();
120 int* ids =
new int[nrows];
121 int* iovid_vec =
new int[nrows];
122 float*
xx =
new float[nrows];
123 float*
yy =
new float[nrows];
125 ub2* ids_len =
new ub2[nrows];
126 ub2* iov_len =
new ub2[nrows];
127 ub2* x_len =
new ub2[nrows];
128 ub2* y_len =
new ub2[nrows];
133 typedef map<EcalLogicID, MonH4TablePositionDat>::const_iterator CI;
134 for (CI
p =
data->begin();
p !=
data->end(); ++
p) {
135 channel = &(
p->first);
138 throw(std::runtime_error(
"MonH4TablePositionDat::writeArrayDB: Bad EcalLogicID"));
140 ids[
count] = logicID;
141 iovid_vec[
count] = iovID;
143 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, OCCIFLOAT,
sizeof(
xx[0]), x_len);
164 m_writeStmt->setDataBuffer(4, (dvoid*)
yy, OCCIFLOAT,
sizeof(
yy[0]), y_len);
178 }
catch (SQLException&
e) {
179 throw(std::runtime_error(
"MonH4TablePositionDat::writeArrayDB(): " +
e.getMessage()));
References submitPVResolutionJobs::count, data, MillePedeFileConverter_cfg::e, EcalLogicID::getLogicID(), getTableX(), getTableY(), AlCaHLTBitMon_ParallelJobs::p, x, geometryCSVtoXML::xx, y, and geometryCSVtoXML::yy.
◆ writeDB()
Definition at line 37 of file MonH4TablePositionDat.cc.
45 throw(std::runtime_error(
"MonH4TablePositionDat::writeDB: IOV not in DB"));
50 throw(std::runtime_error(
"MonH4TablePositionDat::writeDB: Bad EcalLogicID"));
61 }
catch (SQLException&
e) {
62 throw(std::runtime_error(
"MonH4TablePositionDat::writeDB(): " +
e.getMessage()));
References MillePedeFileConverter_cfg::e, and B2GTnPMonitor_cfi::item.
◆ EcalCondDBInterface
◆ m_tableX
float MonH4TablePositionDat::m_tableX |
|
private |
◆ m_tableY
float MonH4TablePositionDat::m_tableY |
|
private |