Alignment
CommonAlignmentProducer
plugins
FakeAlignmentProducer.cc
Go to the documentation of this file.
1
// -*- C++ -*-
2
//
3
// Package: FakeAlignmentProducer
4
// Class: FakeAlignmentProducer
5
//
15
//
16
// Original Author: Frederic Ronga
17
// Created: Fri Feb 9 19:24:38 CET 2007
18
// $Id: FakeAlignmentProducer.cc,v 1.6 2008/06/26 10:00:35 flucke Exp $
19
//
20
//
21
22
// System
23
#include <memory>
24
25
// Framework
26
#include "
FWCore/Framework/interface/ModuleFactory.h
"
27
#include "
FWCore/Framework/interface/ESProducer.h
"
28
#include "
FWCore/MessageLogger/interface/MessageLogger.h
"
29
30
// Alignment
31
#include "
CondFormats/Alignment/interface/Alignments.h
"
32
#include "
CondFormats/Alignment/interface/AlignmentErrorsExtended.h
"
33
#include "
CondFormats/AlignmentRecord/interface/TrackerAlignmentRcd.h
"
34
#include "
CondFormats/AlignmentRecord/interface/DTAlignmentRcd.h
"
35
#include "
CondFormats/AlignmentRecord/interface/CSCAlignmentRcd.h
"
36
#include "
CondFormats/AlignmentRecord/interface/TrackerAlignmentErrorExtendedRcd.h
"
37
#include "
CondFormats/AlignmentRecord/interface/DTAlignmentErrorExtendedRcd.h
"
38
#include "
CondFormats/AlignmentRecord/interface/CSCAlignmentErrorExtendedRcd.h
"
39
#include "
CondFormats/AlignmentRecord/interface/GlobalPositionRcd.h
"
40
41
class
FakeAlignmentProducer
:
public
edm::ESProducer
{
42
public
:
43
FakeAlignmentProducer
(
const
edm::ParameterSet
&);
44
~FakeAlignmentProducer
()
override
{}
45
46
std::unique_ptr<Alignments>
produceTkAli
(
const
TrackerAlignmentRcd
&) {
return
std::make_unique<Alignments>(); }
47
std::unique_ptr<Alignments>
produceDTAli
(
const
DTAlignmentRcd
&) {
return
std::make_unique<Alignments>(); }
48
std::unique_ptr<Alignments>
produceCSCAli
(
const
CSCAlignmentRcd
&) {
return
std::make_unique<Alignments>(); }
49
std::unique_ptr<Alignments>
produceGlobals
(
const
GlobalPositionRcd
&) {
return
std::make_unique<Alignments>(); }
50
51
std::unique_ptr<AlignmentErrorsExtended>
produceTkAliErr
(
const
TrackerAlignmentErrorExtendedRcd
&) {
52
return
std::make_unique<AlignmentErrorsExtended>();
53
}
54
std::unique_ptr<AlignmentErrorsExtended>
produceDTAliErr
(
const
DTAlignmentErrorExtendedRcd
&) {
55
return
std::make_unique<AlignmentErrorsExtended>();
56
}
57
std::unique_ptr<AlignmentErrorsExtended>
produceCSCAliErr
(
const
CSCAlignmentErrorExtendedRcd
&) {
58
return
std::make_unique<AlignmentErrorsExtended>();
59
}
60
};
61
62
FakeAlignmentProducer::FakeAlignmentProducer
(
const
edm::ParameterSet
& iConfig) {
63
// This 'appendToDataLabel' is used by the framework to distinguish providers
64
// with different settings and to request a special one by e.g.
65
// iSetup.get<TrackerDigiGeometryRecord>().get("theLabel", tkGeomHandle);
66
edm::LogInfo
(
"Alignments"
) <<
"@SUB=FakeAlignmentProducer"
67
<<
"Providing data with label '"
<< iConfig.
getParameter
<
std::string
>(
"appendToDataLabel"
)
68
<<
"'."
;
69
70
setWhatProduced
(
this
, &
FakeAlignmentProducer::produceTkAli
);
71
setWhatProduced
(
this
, &
FakeAlignmentProducer::produceTkAliErr
);
72
setWhatProduced
(
this
, &
FakeAlignmentProducer::produceDTAli
);
73
setWhatProduced
(
this
, &
FakeAlignmentProducer::produceDTAliErr
);
74
setWhatProduced
(
this
, &
FakeAlignmentProducer::produceCSCAli
);
75
setWhatProduced
(
this
, &
FakeAlignmentProducer::produceCSCAliErr
);
76
setWhatProduced
(
this
, &
FakeAlignmentProducer::produceGlobals
);
77
}
78
79
//define this as a plug-in
80
DEFINE_FWK_EVENTSETUP_MODULE
(
FakeAlignmentProducer
);
AlignmentErrorsExtended.h
GlobalPositionRcd.h
FakeAlignmentProducer::produceTkAli
std::unique_ptr< Alignments > produceTkAli(const TrackerAlignmentRcd &)
Definition:
FakeAlignmentProducer.cc:46
MessageLogger.h
FakeAlignmentProducer::produceDTAliErr
std::unique_ptr< AlignmentErrorsExtended > produceDTAliErr(const DTAlignmentErrorExtendedRcd &)
Definition:
FakeAlignmentProducer.cc:54
FakeAlignmentProducer::~FakeAlignmentProducer
~FakeAlignmentProducer() override
Definition:
FakeAlignmentProducer.cc:44
DTAlignmentErrorExtendedRcd.h
edm::ESProducer::setWhatProduced
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition:
ESProducer.h:163
ESProducer.h
Alignments.h
FakeAlignmentProducer::produceDTAli
std::unique_ptr< Alignments > produceDTAli(const DTAlignmentRcd &)
Definition:
FakeAlignmentProducer.cc:47
TrackerAlignmentRcd
Definition:
TrackerAlignmentRcd.h:6
edm::LogInfo
Log< level::Info, false > LogInfo
Definition:
MessageLogger.h:125
FakeAlignmentProducer::produceGlobals
std::unique_ptr< Alignments > produceGlobals(const GlobalPositionRcd &)
Definition:
FakeAlignmentProducer.cc:49
GlobalPositionRcd
Definition:
GlobalPositionRcd.h:6
TrackerAlignmentErrorExtendedRcd.h
DTAlignmentRcd
Definition:
DTAlignmentRcd.h:6
CSCAlignmentErrorExtendedRcd.h
DTAlignmentErrorExtendedRcd
Definition:
DTAlignmentErrorExtendedRcd.h:6
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
CSCAlignmentErrorExtendedRcd
Definition:
CSCAlignmentErrorExtendedRcd.h:6
edm::ParameterSet
Definition:
ParameterSet.h:47
DTAlignmentRcd.h
TrackerAlignmentRcd.h
FakeAlignmentProducer::produceCSCAli
std::unique_ptr< Alignments > produceCSCAli(const CSCAlignmentRcd &)
Definition:
FakeAlignmentProducer.cc:48
ModuleFactory.h
DEFINE_FWK_EVENTSETUP_MODULE
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
Definition:
ModuleFactory.h:60
FakeAlignmentProducer::produceCSCAliErr
std::unique_ptr< AlignmentErrorsExtended > produceCSCAliErr(const CSCAlignmentErrorExtendedRcd &)
Definition:
FakeAlignmentProducer.cc:57
FakeAlignmentProducer::FakeAlignmentProducer
FakeAlignmentProducer(const edm::ParameterSet &)
Definition:
FakeAlignmentProducer.cc:62
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition:
ParameterSet.h:303
FakeAlignmentProducer
Definition:
FakeAlignmentProducer.cc:41
edm::ESProducer
Definition:
ESProducer.h:104
TrackerAlignmentErrorExtendedRcd
Definition:
TrackerAlignmentErrorExtendedRcd.h:6
FakeAlignmentProducer::produceTkAliErr
std::unique_ptr< AlignmentErrorsExtended > produceTkAliErr(const TrackerAlignmentErrorExtendedRcd &)
Definition:
FakeAlignmentProducer.cc:51
CSCAlignmentRcd
Definition:
CSCAlignmentRcd.h:6
CSCAlignmentRcd.h
Generated for CMSSW Reference Manual by
1.8.16