93 typedef std::map<std::string, std::string>::const_iterator recordIter;
95 container = (*i).first;
100 if (container ==
"EcalLaserAPDPNRatios") {
118 int hi = ebdetid.hashedIndex();
120 if (hi < static_cast<int>(laserRatiosMap.
size())) {
121 apdpnpair = laserRatiosMap[hi];
122 std::cout <<
"A sample value of APDPN pair EB : " << hi <<
" : " << apdpnpair.
p1 <<
" , " << apdpnpair.
p2 125 edm::LogError(
"EcalGetLaserData") <<
"error with laserRatiosMap!" << std::endl;
137 int hi = eedetidpos.hashedIndex();
139 if (hi < static_cast<int>(laserRatiosMap.
size())) {
140 apdpnpair = laserRatiosMap[hi];
141 std::cout <<
"A sample value of APDPN pair EE+ : " << hi <<
" : " << apdpnpair.
p1 <<
" , " << apdpnpair.
p2 144 edm::LogError(
"EcalGetLaserData") <<
"error with laserRatiosMap!" << std::endl;
150 hi = eedetidneg.hashedIndex();
152 if (hi < static_cast<int>(laserRatiosMap.
size())) {
153 apdpnpair = laserRatiosMap[hi];
154 std::cout <<
"A sample value of APDPN pair EE- : " << hi <<
" : " << apdpnpair.
p1 <<
" , " << apdpnpair.
p2 157 edm::LogError(
"EcalGetLaserData") <<
"error with laserRatiosMap!" << std::endl;
162 for (
int i = 0;
i < 92;
i++) {
163 timestamp = laserTimeMap[
i];
168 std::cout <<
".. just retrieved the last valid record from DB " << std::endl;
170 }
else if (container ==
"EcalLaserAPDPNRatiosRef") {
184 int hi = ebdetid.hashedIndex();
186 if (hi < static_cast<int>(laserRefMap.
size())) {
187 apdpnref = laserRefMap[hi];
188 std::cout <<
"A sample value of APDPN Reference value EB : " << hi <<
" : " << apdpnref << std::endl;
190 edm::LogError(
"EcalGetLaserData") <<
"error with laserRefMap!" << std::endl;
202 int hi = eedetidpos.hashedIndex();
204 if (hi < static_cast<int>(laserRefMap.
size())) {
205 apdpnref = laserRefMap[hi];
206 std::cout <<
"A sample value of APDPN Reference value EE+ : " << hi <<
" : " << apdpnref << std::endl;
209 edm::LogError(
"EcalGetLaserData") <<
"error with laserRefMap!" << std::endl;
214 EEDetId eedetidneg(iX, iY, -1);
215 hi = eedetidneg.hashedIndex();
217 if (hi < static_cast<int>(laserRefMap.
size())) {
218 apdpnref = laserRefMap[hi];
219 std::cout <<
"A sample value of APDPN Reference value EE- : " << hi <<
" : " << apdpnref << std::endl;
221 edm::LogError(
"EcalGetLaserData") <<
"error with laserRefMap!" << std::endl;
226 std::cout <<
"... just retrieved the last valid record from DB " << std::endl;
228 }
else if (container ==
"EcalLaserAlphas") {
243 int hi = ebdetid.hashedIndex();
245 if (hi < static_cast<int>(laserAlphaMap.
size())) {
246 alpha = laserAlphaMap[hi];
247 std::cout <<
" A sample value of Alpha value EB : " << hi <<
" : " << alpha << std::endl;
249 edm::LogError(
"EcalGetLaserData") <<
"error with laserAlphaMap!" << std::endl;
261 int hi = eedetidpos.hashedIndex();
263 if (hi < static_cast<int>(laserAlphaMap.
size())) {
264 alpha = laserAlphaMap[hi];
265 std::cout <<
" A sample value of Alpha value EE+ : " << hi <<
" : " << alpha << std::endl;
267 edm::LogError(
"EcalGetLaserData") <<
"error with laserAlphaMap!" << std::endl;
272 EEDetId eedetidneg(iX, iY, -1);
273 hi = eedetidneg.hashedIndex();
275 if (hi < static_cast<int>(laserAlphaMap.
size())) {
276 alpha = laserAlphaMap[hi];
277 std::cout <<
" A sample value of Alpha value EE- : " << hi <<
" : " << alpha << std::endl;
279 edm::LogError(
"EcalGetLaserData") <<
"error with laserAlphaMap!" << std::endl;
284 std::cout <<
"... just retrieved the last valid record from DB " << std::endl;
287 edm::LogError(
"EcalGetLaserData") <<
"Cannot retrieve for container: " << container << std::endl;
static const int MIN_IPHI
std::map< std::string, std::string > m_records
const self & getMap() const
const EcalLaserAPDPNRatiosMap & getLaserMap() const
static const int MAX_IPHI
const EcalLaserTimeStampMap & getTimeMap() const
std::vector< EcalLaserTimeStamp > EcalLaserTimeStampMap
static bool validDetId(int crystal_ix, int crystal_iy, int iz)
static const int MAX_IETA
alpha
zGenParticlesMatch = cms.InputTag(""),
T const * product() const
TimeValue_t value() const