CMS 3D CMS Logo

CTPPSRPAlignmentInfoReader.cc
Go to the documentation of this file.
1 // system include files
2 #include <memory>
3 #include <iostream>
11 
16 
17 using namespace std;
18 
20 public:
23 
25  : iov_(iConfig.getParameter<unsigned long long>("iov")), record_(iConfig.getParameter<string>("record")) {}
26  explicit CTPPSRPAlignmentInfoReader(int i) {}
28  void analyze(const edm::Event& e, const edm::EventSetup& c) override;
29  void printInfo(const CTPPSRPAlignmentCorrectionsData& alignments, const edm::Event& event);
30 };
31 
33  using namespace edm;
34 
35  //this part gets the handle of the event source and the record (i.e. the Database)
36  if (e.id().run() == iov_) {
38  if (strcmp(record_.c_str(), "CTPPSRPAlignmentCorrectionsDataRcd") == 0) {
39  context.get<CTPPSRPAlignmentCorrectionsDataRcd>().get(alignments);
40  } else if (strcmp(record_.c_str(), "RPRealAlignmentRecord") == 0) {
41  context.get<RPRealAlignmentRecord>().get(alignments);
42  } else {
43  context.get<RPMisalignedAlignmentRecord>().get(alignments);
44  }
45 
46  //std::cout
47  edm::LogPrint("CTPPSRPAlignmentInfoReader")
48  << "New alignments found in run=" << e.id().run() << ", event=" << e.id().event() << ":\n"
49  << *alignments;
50  }
51 }
52 
EDAnalyzer.h
mps_fire.i
i
Definition: mps_fire.py:428
MessageLogger.h
ESHandle.h
edm
HLT enums.
Definition: AlignableModifier.h:19
edm::LogPrint
Log< level::Warning, true > LogPrint
Definition: MessageLogger.h:130
CTPPSRPAlignmentInfoReader::~CTPPSRPAlignmentInfoReader
~CTPPSRPAlignmentInfoReader() override
Definition: CTPPSRPAlignmentInfoReader.cc:27
CTPPSRPAlignmentCorrectionsDataRcd
Definition: CTPPSRPAlignmentCorrectionsDataRcd.h:23
CTPPSRPAlignmentInfoReader::iov_
cond::Time_t iov_
Definition: CTPPSRPAlignmentInfoReader.cc:21
edm::one::EDAnalyzer
Definition: EDAnalyzer.h:30
RPMisalignedAlignmentRecord
Definition: RPMisalignedAlignmentRecord.h:6
RPMisalignedAlignmentRecord.h
CTPPSRPAlignmentInfoReader::CTPPSRPAlignmentInfoReader
CTPPSRPAlignmentInfoReader(int i)
Definition: CTPPSRPAlignmentInfoReader.cc:26
MakerMacros.h
RPRealAlignmentRecord
Definition: RPRealAlignmentRecord.h:6
edm::EventSetup::get
T get() const
Definition: EventSetup.h:80
DEFINE_FWK_MODULE
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
RPRealAlignmentRecord.h
edm::ESHandle
Definition: DTSurvey.h:22
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
Time.h
edm::ParameterSet
Definition: ParameterSet.h:47
Event.h
cond::Time_t
unsigned long long Time_t
Definition: Time.h:14
CTPPSRPAlignmentInfoReader::CTPPSRPAlignmentInfoReader
CTPPSRPAlignmentInfoReader(edm::ParameterSet const &iConfig)
Definition: CTPPSRPAlignmentInfoReader.cc:24
analyze
example_stream void analyze(const edm::Event &, const edm::EventSetup &) override
objects.IsoTrackAnalyzer.printInfo
def printInfo(self, event)
Definition: IsoTrackAnalyzer.py:252
edm::EventSetup
Definition: EventSetup.h:57
HltBtagPostValidation_cff.c
c
Definition: HltBtagPostValidation_cff.py:31
get
#define get
CTPPSRPAlignmentCorrectionsDataRcd.h
CTPPSRPAlignmentInfoReader::record_
std::string record_
Definition: CTPPSRPAlignmentInfoReader.cc:22
std
Definition: JetResolutionObject.h:76
CTPPSRPAlignmentCorrectionsData
Container for CTPPS RP alignment corrections. The corrections are stored on two levels - RP and senso...
Definition: CTPPSRPAlignmentCorrectionsData.h:24
EventSetup.h
CTPPSRPAlignmentCorrectionsData.h
CTPPSRPAlignmentInfoReader::analyze
void analyze(const edm::Event &e, const edm::EventSetup &c) override
Definition: CTPPSRPAlignmentInfoReader.cc:32
event
Definition: event.py:1
edm::Event
Definition: Event.h:73
CTPPSRPAlignmentInfoReader
Definition: CTPPSRPAlignmentInfoReader.cc:19
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37