#include <MonShapeQualityDat.h>
Definition at line 12 of file MonShapeQualityDat.h.
◆ MonShapeQualityDat()
MonShapeQualityDat::MonShapeQualityDat |
( |
| ) |
|
◆ ~MonShapeQualityDat()
MonShapeQualityDat::~MonShapeQualityDat |
( |
| ) |
|
|
override |
◆ fetchData()
Definition at line 66 of file MonShapeQualityDat.cc.
79 "SELECT cv.name, cv.logic_id, cv.id1, cv.id2, cv.id3, cv.maps_to, "
81 "FROM channelview cv JOIN mon_shape_quality_dat d "
82 "ON cv.logic_id = d.logic_id AND cv.name = cv.maps_to "
83 "WHERE d.iov_id = :iov_id");
87 std::pair<EcalLogicID, MonShapeQualityDat>
p;
89 while (rset->next()) {
102 }
catch (SQLException&
e) {
103 throw(std::runtime_error(
"MonShapeQualityDat::fetchData(): " +
e.getMessage()));
References MillePedeFileConverter_cfg::e, AlCaHLTBitMon_ParallelJobs::p, and setAvgChi2().
◆ getAvgChi2()
float MonShapeQualityDat::getAvgChi2 |
( |
| ) |
const |
|
inline |
◆ getTable()
std::string MonShapeQualityDat::getTable |
( |
| ) |
|
|
inlineoverridevirtual |
◆ prepareWrite()
void MonShapeQualityDat::prepareWrite |
( |
| ) |
|
|
overrideprivatevirtualnoexcept |
Implements IDataItem.
Definition at line 23 of file MonShapeQualityDat.cc.
29 "INSERT INTO mon_shape_quality_dat (iov_id, logic_id, "
31 "VALUES (:iov_id, :logic_id, "
33 }
catch (SQLException&
e) {
34 throw(std::runtime_error(
"MonShapeQualityDat::prepareWrite(): " +
e.getMessage()));
References MillePedeFileConverter_cfg::e.
◆ setAvgChi2()
void MonShapeQualityDat::setAvgChi2 |
( |
float |
chi2 | ) |
|
|
inline |
◆ writeArrayDB()
Definition at line 107 of file MonShapeQualityDat.cc.
114 throw(std::runtime_error(
"MonShapeQualityDat::writeArrayDB: IOV not in DB"));
117 int nrows =
data->size();
118 int* ids =
new int[nrows];
119 int* iovid_vec =
new int[nrows];
120 float*
xx =
new float[nrows];
122 ub2* ids_len =
new ub2[nrows];
123 ub2* iov_len =
new ub2[nrows];
124 ub2* x_len =
new ub2[nrows];
129 typedef map<EcalLogicID, MonShapeQualityDat>::const_iterator CI;
130 for (CI
p =
data->begin();
p !=
data->end(); ++
p) {
131 channel = &(
p->first);
134 throw(std::runtime_error(
"MonShapeQualityDat::writeArrayDB: Bad EcalLogicID"));
136 ids[
count] = logicID;
137 iovid_vec[
count] = iovID;
139 dataitem = &(
p->second);
154 m_writeStmt->setDataBuffer(1, (dvoid*)iovid_vec, OCCIINT,
sizeof(iovid_vec[0]), iov_len);
155 m_writeStmt->setDataBuffer(2, (dvoid*)ids, OCCIINT,
sizeof(ids[0]), ids_len);
156 m_writeStmt->setDataBuffer(3, (dvoid*)
xx, OCCIFLOAT,
sizeof(
xx[0]), x_len);
168 }
catch (SQLException&
e) {
169 throw(std::runtime_error(
"MonPedestalsDat::writeArrayDB(): " +
e.getMessage()));
References KineDebug3::count(), std::data(), MillePedeFileConverter_cfg::e, getAvgChi2(), EcalLogicID::getLogicID(), AlCaHLTBitMon_ParallelJobs::p, x, and geometryCSVtoXML::xx.
◆ writeDB()
Definition at line 38 of file MonShapeQualityDat.cc.
46 throw(std::runtime_error(
"MonShapeQualityDat::writeDB: IOV not in DB"));
51 throw(std::runtime_error(
"MonShapeQualityDat::writeDB: Bad EcalLogicID"));
61 }
catch (SQLException&
e) {
62 throw(std::runtime_error(
"MonShapeQualityDat::writeDB(): " +
e.getMessage()));
References MillePedeFileConverter_cfg::e, and B2GTnPMonitor_cfi::item.
◆ EcalCondDBInterface
◆ m_avgChi2
float MonShapeQualityDat::m_avgChi2 |
|
private |