CondTools
Ecal
plugins
EcalFloatCondObjectContainerHandler.cc
Go to the documentation of this file.
1
9
#include "
FWCore/ParameterSet/interface/ParameterSet.h
"
10
#include "
CondCore/CondDB/interface/Time.h
"
11
#include "
CondTools/Ecal/interface/EcalFloatCondObjectContainerHandler.h
"
12
#include "
CondTools/Ecal/interface/EcalFloatCondObjectContainerXMLTranslator.h
"
13
#include "
CondTools/Ecal/interface/DOMHelperFunctions.h
"
14
#include <utility>
15
16
EcalFloatCondObjectContainerHandler::~EcalFloatCondObjectContainerHandler
() {}
17
18
EcalFloatCondObjectContainerHandler::EcalFloatCondObjectContainerHandler
(
const
edm::ParameterSet
&ps)
19
: xmlFileSource_(ps.getUntrackedParameter<
std
::
string
>(
"xmlFile"
)),
20
since_(ps.getUntrackedParameter<long long>(
"since"
)) {}
21
22
void
EcalFloatCondObjectContainerHandler::getNewObjects
() {
23
EcalCondHeader
header
;
24
25
// we allocate on the heap here, knowing that popcon will
26
// take care of deleting the payload
27
EcalFloatCondObjectContainer
*
payload
=
new
EcalFloatCondObjectContainer
;
28
29
EcalFloatCondObjectContainerXMLTranslator::readXML
(
xmlFileSource_
,
header
, *
payload
);
30
31
//cond::Time_t snc = header.since_;
32
//for now we don't make use of the xml header to read the since
33
//but rely on the one passed from parameter set
34
35
m_to_transfer
.push_back(std::make_pair(
payload
,
since_
));
36
}
37
38
std::string
EcalFloatCondObjectContainerHandler::id
()
const
{
39
// We have to think if this is the right thing to do ...
40
41
EcalCondHeader
header
;
42
xuti::readHeader
(
xmlFileSource_
,
header
);
43
return
header
.tag_;
44
}
45
46
// Configure (x)emacs for this file ...
47
// Local Variables:
48
// mode:c++
49
// compile-command: "scram b"
50
// End:
popcon::PopConSourceHandler< EcalFloatCondObjectContainer >::m_to_transfer
OldContainer m_to_transfer
Definition:
PopConSourceHandler.h:162
EcalFloatCondObjectContainerHandler::~EcalFloatCondObjectContainerHandler
~EcalFloatCondObjectContainerHandler() override
Definition:
EcalFloatCondObjectContainerHandler.cc:16
EcalCondObjectContainer
Definition:
EcalCondObjectContainer.h:13
EcalFloatCondObjectContainerXMLTranslator::readXML
static int readXML(const std::string &filename, EcalCondHeader &header, EcalFloatCondObjectContainer &record)
Definition:
EcalFloatCondObjectContainerXMLTranslator.cc:23
EcalFloatCondObjectContainerHandler::EcalFloatCondObjectContainerHandler
EcalFloatCondObjectContainerHandler(const edm::ParameterSet &ps)
Definition:
EcalFloatCondObjectContainerHandler.cc:18
jets_cff.payload
payload
Definition:
jets_cff.py:32
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
Time.h
edm::ParameterSet
Definition:
ParameterSet.h:47
DOMHelperFunctions.h
EcalFloatCondObjectContainerHandler::getNewObjects
void getNewObjects() override
Definition:
EcalFloatCondObjectContainerHandler.cc:22
EcalCondHeader
Definition:
EcalCondHeader.h:16
EcalFloatCondObjectContainerXMLTranslator.h
EcalFloatCondObjectContainerHandler.h
std
Definition:
JetResolutionObject.h:76
EcalFloatCondObjectContainerHandler::id
std::string id() const override
Definition:
EcalFloatCondObjectContainerHandler.cc:38
EcalFloatCondObjectContainerHandler::xmlFileSource_
std::string xmlFileSource_
Definition:
EcalFloatCondObjectContainerHandler.h:37
RecoTauValidation_cfi.header
header
Definition:
RecoTauValidation_cfi.py:292
ParameterSet.h
EcalFloatCondObjectContainer
EcalCondObjectContainer< float > EcalFloatCondObjectContainer
Definition:
EcalCondObjectContainer.h:189
xuti::readHeader
void readHeader(xercesc::DOMNode *parentNode, EcalCondHeader &header)
read header from
Definition:
DOMHelperFunctions.cc:164
EcalFloatCondObjectContainerHandler::since_
long long since_
Definition:
EcalFloatCondObjectContainerHandler.h:38
Generated for CMSSW Reference Manual by
1.8.16