CondTools
Hcal
src
HcalTPParametersHandler.cc
Go to the documentation of this file.
1
#include "
CondTools/Hcal/interface/HcalTPParametersHandler.h
"
2
#include "
DataFormats/DetId/interface/DetId.h
"
3
#include "
DataFormats/HcalDetId/interface/HcalGenericDetId.h
"
4
#include <memory>
5
6
HcalTPParametersHandler::HcalTPParametersHandler
(
edm::ParameterSet
const
& ps) {
7
m_name
= ps.
getUntrackedParameter
<
std::string
>(
"name"
,
"HcalTPParametersHandler"
);
8
sinceTime
= ps.
getUntrackedParameter
<
unsigned
>(
"IOVRun"
, 0);
9
}
10
11
HcalTPParametersHandler::~HcalTPParametersHandler
() {}
12
13
void
HcalTPParametersHandler::getNewObjects
() {
14
edm::LogInfo
(
"HcalCondTools"
) <<
"------- "
<<
m_name
<<
" - > getNewObjects\n"
15
<<
"got offlineInfo"
<<
tagInfo
().
name
<<
", size "
<<
tagInfo
().
size
16
<<
", last object valid since "
<<
tagInfo
().
lastInterval
.
since
<< std::endl;
17
18
if
(!
myDBObject
)
19
throw
cms::Exception
(
"Empty DB object"
)
20
<<
m_name
<<
" has received empty object - nothing to write to DB"
<< std::endl;
21
22
// IOV information
23
cond::Time_t
myTime =
sinceTime
;
24
25
edm::LogInfo
(
"HcalCondTools"
) <<
"Using IOV run "
<<
sinceTime
<< std::endl;
26
27
// prepare for transfer:
28
m_to_transfer
.push_back(std::make_pair(
myDBObject
, myTime));
29
30
edm::LogInfo
(
"HcalCondTools"
) <<
"------- "
<<
m_name
<<
" - > getNewObjects"
<< std::endl;
31
}
32
33
void
HcalTPParametersHandler::initObject
(
HcalTPParameters
* fObject) {
myDBObject
= fObject; }
popcon::PopConSourceHandler< HcalTPParameters >::m_to_transfer
OldContainer m_to_transfer
Definition:
PopConSourceHandler.h:162
HcalTPParameters
Definition:
HcalTPParameters.h:10
edm::LogInfo
Definition:
MessageLogger.h:254
HcalGenericDetId.h
HcalTPParametersHandler::HcalTPParametersHandler
HcalTPParametersHandler(edm::ParameterSet const &)
Definition:
HcalTPParametersHandler.cc:6
edm::ParameterSet::getUntrackedParameter
T getUntrackedParameter(std::string const &, T const &) const
cond::TagInfo_t::name
std::string name
Definition:
Types.h:72
HcalTPParametersHandler.h
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
edm::ParameterSet
Definition:
ParameterSet.h:36
popcon::PopConSourceHandler< HcalTPParameters >::tagInfo
cond::TagInfo_t const & tagInfo() const
Definition:
PopConSourceHandler.h:78
cond::Iov_t::since
Time_t since
Definition:
Types.h:53
HcalTPParametersHandler::myDBObject
HcalTPParameters * myDBObject
Definition:
HcalTPParametersHandler.h:33
cond::Time_t
unsigned long long Time_t
Definition:
Time.h:14
HcalTPParametersHandler::m_name
std::string m_name
Definition:
HcalTPParametersHandler.h:34
HcalTPParametersHandler::sinceTime
unsigned int sinceTime
Definition:
HcalTPParametersHandler.h:31
HcalTPParametersHandler::getNewObjects
void getNewObjects() override
Definition:
HcalTPParametersHandler.cc:13
cond::TagInfo_t::lastInterval
Iov_t lastInterval
Definition:
Types.h:73
HcalTPParametersHandler::~HcalTPParametersHandler
~HcalTPParametersHandler() override
Definition:
HcalTPParametersHandler.cc:11
DetId.h
HcalTPParametersHandler::initObject
void initObject(HcalTPParameters *)
Definition:
HcalTPParametersHandler.cc:33
Exception
Definition:
hltDiff.cc:246
cond::TagInfo_t::size
size_t size
Definition:
Types.h:74
Generated for CMSSW Reference Manual by
1.8.16