#include <MonPulseShapeDat.h>
Definition at line 13 of file MonPulseShapeDat.h.
◆ MonPulseShapeDat()
MonPulseShapeDat::MonPulseShapeDat |
( |
| ) |
|
Definition at line 12 of file MonPulseShapeDat.cc.
oracle::occi::Environment * m_env
oracle::occi::Statement * m_writeStmt
oracle::occi::Connection * m_conn
std::vector< float > m_samplesG1
std::vector< float > m_samplesG6
std::vector< float > m_samplesG12
oracle::occi::Statement * m_readStmt
◆ ~MonPulseShapeDat()
MonPulseShapeDat::~MonPulseShapeDat |
( |
| ) |
|
|
override |
◆ fetchData()
Definition at line 86 of file MonPulseShapeDat.cc.
References MillePedeFileConverter_cfg::e, PedestalClient_cfi::gain, mps_fire::i, dqmiolumiharvest::j, AlCaHLTBitMon_ParallelJobs::p, EgammaValidation_cff::samples, and setSamples().
99 "SELECT cv.name, cv.logic_id, cv.id1, cv.id2, cv.id3, cv.maps_to, " 100 "d.g1_avg_sample_01, d.g1_avg_sample_02, d.g1_avg_sample_03, d.g1_avg_sample_04, d.g1_avg_sample_05, " 101 "d.g1_avg_sample_06, d.g1_avg_sample_07, d.g1_avg_sample_08, d.g1_avg_sample_09, d.g1_avg_sample_10, " 102 "d.g6_avg_sample_01, d.g6_avg_sample_02, d.g6_avg_sample_03, d.g6_avg_sample_04, d.g6_avg_sample_05, " 103 "d.g6_avg_sample_06, d.g6_avg_sample_07, d.g6_avg_sample_08, d.g6_avg_sample_09, d.g6_avg_sample_10, " 104 "d.g12_avg_sample_01, d.g12_avg_sample_02, d.g12_avg_sample_03, d.g12_avg_sample_04, d.g12_avg_sample_05, " 105 "d.g12_avg_sample_06, d.g12_avg_sample_07, d.g12_avg_sample_08, d.g12_avg_sample_09, d.g12_avg_sample_10 " 106 "FROM channelview cv JOIN mon_pulse_shape_dat d " 107 "ON cv.logic_id = d.logic_id AND cv.name = cv.maps_to " 108 "WHERE d.iov_id = :iov_id");
112 std::pair<EcalLogicID, MonPulseShapeDat>
p;
114 while (rset->next()) {
122 int gain[] = {1, 6, 12};
123 std::vector<float>
samples(10);
124 for (
int i = 0;
i < 3;
i++) {
126 for (
int j = 0;
j < 10;
j++) {
127 samples.push_back(rset->getFloat(7 + (10 *
i) +
j));
135 }
catch (SQLException&
e) {
136 throw(std::runtime_error(
"MonPulseShapeDat::fetchData: " +
e.getMessage()));
oracle::occi::Environment * m_env
oracle::occi::Connection * m_conn
void checkConnection() const noexcept(false)
void setSamples(std::vector< float > &samples, int gain) noexcept(false)
int fetchID() noexcept(false) override
oracle::occi::Statement * m_readStmt
void setConnection(oracle::occi::Environment *env, oracle::occi::Connection *conn)
◆ getSamples()
std::vector<float> MonPulseShapeDat::getSamples |
( |
int |
gain | ) |
const |
|
inlinenoexcept |
◆ getTable()
std::string MonPulseShapeDat::getTable |
( |
| ) |
|
|
inlineoverridevirtual |
◆ prepareWrite()
void MonPulseShapeDat::prepareWrite |
( |
| ) |
|
|
overrideprivatevirtualnoexcept |
Implements IDataItem.
Definition at line 25 of file MonPulseShapeDat.cc.
References MillePedeFileConverter_cfg::e.
31 "INSERT INTO mon_pulse_shape_dat (iov_id, logic_id, " 32 "g1_avg_sample_01, g1_avg_sample_02, g1_avg_sample_03, g1_avg_sample_04, g1_avg_sample_05, g1_avg_sample_06, " 33 "g1_avg_sample_07, g1_avg_sample_08, g1_avg_sample_09, g1_avg_sample_10, " 34 "g6_avg_sample_01, g6_avg_sample_02, g6_avg_sample_03, g6_avg_sample_04, g6_avg_sample_05, g6_avg_sample_06, " 35 "g6_avg_sample_07, g6_avg_sample_08, g6_avg_sample_09, g6_avg_sample_10, " 36 "g12_avg_sample_01, g12_avg_sample_02, g12_avg_sample_03, g12_avg_sample_04, g12_avg_sample_05, " 37 "g12_avg_sample_06, g12_avg_sample_07, g12_avg_sample_08, g12_avg_sample_09, g12_avg_sample_10) " 38 "VALUES (:iov_id, :logic_id, " 39 ":g1_avg_sample_01, :g1_avg_sample_02, :g1_avg_sample_03, :g1_avg_sample_04, :g1_avg_sample_05, " 40 ":g1_avg_sample_06, :g1_avg_sample_07, :g1_avg_sample_08, :g1_avg_sample_09, :g1_avg_sample_10," 41 ":g6_avg_sample_01, :g6_avg_sample_02, :g6_avg_sample_03, :g6_avg_sample_04, :g6_avg_sample_05, " 42 ":g6_avg_sample_06, :g6_avg_sample_07, :g6_avg_sample_08, :g6_avg_sample_09, :g6_avg_sample_10," 43 ":g12_avg_sample_01, :g12_avg_sample_02, :g12_avg_sample_03, :g12_avg_sample_04, :g12_avg_sample_05, " 44 ":g12_avg_sample_06, :g12_avg_sample_07, :g12_avg_sample_08, :g12_avg_sample_09, :g12_avg_sample_10)");
46 }
catch (SQLException&
e) {
47 throw(std::runtime_error(
"MonPulseShapeDat::prepareWrite(): " +
e.getMessage()));
oracle::occi::Statement * m_writeStmt
oracle::occi::Connection * m_conn
void checkConnection() const noexcept(false)
◆ setSamples()
void MonPulseShapeDat::setSamples |
( |
std::vector< float > & |
samples, |
|
|
int |
gain |
|
) |
| |
|
inlinenoexcept |
◆ writeDB()
◆ EcalCondDBInterface
◆ m_samplesG1
std::vector<float> MonPulseShapeDat::m_samplesG1 |
|
private |
◆ m_samplesG12
std::vector<float> MonPulseShapeDat::m_samplesG12 |
|
private |
◆ m_samplesG6
std::vector<float> MonPulseShapeDat::m_samplesG6 |
|
private |