Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
CondTools
Ecal
src
EcalADCToGeVHandler.cc
Go to the documentation of this file.
1
#include "
CondTools/Ecal/interface/EcalADCToGeVHandler.h
"
2
#include "
FWCore/ParameterSet/interface/ParameterSetfwd.h
"
3
#include "
CondFormats/EcalObjects/interface/EcalIntercalibConstants.h
"
4
#include "
CondTools/Ecal/interface/EcalADCToGeVXMLTranslator.h
"
5
6
7
#include<iostream>
8
9
popcon::EcalADCToGeVHandler::EcalADCToGeVHandler
(
const
edm::ParameterSet
& ps)
10
: m_name(ps.getUntrackedParameter<std::
string
>(
"name"
,
"EcalADCToGeVHandler"
)) {
11
12
std::cout
<<
"EcalADCToGeV Source handler constructor\n"
<< std::endl;
13
m_firstRun
=
static_cast<
unsigned
int
>
(atoi( ps.
getParameter
<
std::string
>(
"firstRun"
).c_str()));
14
m_file_highfield
= ps.
getParameter
<
std::string
>(
"InputFile"
);
15
}
16
17
popcon::EcalADCToGeVHandler::~EcalADCToGeVHandler
() {}
18
19
20
void
popcon::EcalADCToGeVHandler::getNewObjects
() {
21
22
std::cout
<<
"------- Ecal - > getNewObjects\n"
;
23
24
std::ostringstream
ss
;
25
ss<<
"ECAL "
;
26
27
unsigned
int
irun = m_firstRun;
28
29
std::cout
<<
"Generating popcon record for run "
<< irun <<
"..."
<< std::flush;
30
std::string
file_= m_file_highfield;
31
std::cout
<<
"going to open file "
<< file_ << std::flush;
32
33
EcalCondHeader
header;
34
EcalADCToGeVConstant
* payload =
new
EcalADCToGeVConstant
;
35
EcalADCToGeVXMLTranslator::readXML
(file_,header,*payload);
36
37
Time_t
snc= (
Time_t
) irun ;
38
39
popcon::PopConSourceHandler<EcalADCToGeVConstant>::m_to_transfer
.push_back(
40
std::make_pair(payload,snc));
41
42
ss <<
"Run="
<< irun <<
"_Magnet_changed_"
<<std::endl;
43
m_userTextLog = ss.str()+
";"
;
44
45
std::cout
<<
"Ecal - > end of getNewObjects -----------\n"
;
46
}
47
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
popcon::PopConSourceHandler< EcalADCToGeVConstant >::Time_t
cond::Time_t Time_t
Definition:
PopConSourceHandler.h:35
popcon::EcalADCToGeVHandler::getNewObjects
void getNewObjects()
Definition:
EcalADCToGeVHandler.cc:20
EcalADCToGeVXMLTranslator::readXML
static int readXML(const std::string &filename, EcalCondHeader &header, EcalADCToGeVConstant &record)
Definition:
EcalADCToGeVXMLTranslator.cc:23
ParameterSetfwd.h
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:255
popcon::PopConSourceHandler
Definition:
PopConSourceHandler.h:31
popcon::EcalADCToGeVHandler::m_firstRun
unsigned int m_firstRun
Definition:
EcalADCToGeVHandler.h:73
EcalIntercalibConstants.h
EcalCondHeader
Definition:
EcalCondHeader.h:17
popcon::EcalADCToGeVHandler::m_file_highfield
std::string m_file_highfield
Definition:
EcalADCToGeVHandler.h:84
EcalADCToGeVXMLTranslator.h
EcalADCToGeVHandler.h
EcalADCToGeVConstant
Definition:
EcalADCToGeVConstant.h:13
cond::time::Time_t
cond::Time_t Time_t
Definition:
Time.h:17
contentValuesCheck.ss
list ss
Definition:
contentValuesCheck.py:32
popcon::EcalADCToGeVHandler::~EcalADCToGeVHandler
~EcalADCToGeVHandler()
Definition:
EcalADCToGeVHandler.cc:17
popcon::EcalADCToGeVHandler::EcalADCToGeVHandler
EcalADCToGeVHandler(edm::ParameterSet const &)
Definition:
EcalADCToGeVHandler.cc:9
edm::ParameterSet
Definition:
ParameterSet.h:36
gather_cfg.cout
tuple cout
Definition:
gather_cfg.py:145
Generated for CMSSW Reference Manual by
1.8.5