Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
src
TrackingTools
GsfTracking
plugins
GsfMaterialEffectsESProducer.cc
Go to the documentation of this file.
1
#include "
TrackingTools/GsfTracking/plugins/GsfMaterialEffectsESProducer.h
"
2
3
#include "
TrackingTools/MaterialEffects/interface/MultipleScatteringUpdator.h
"
4
#include "
TrackingTools/MaterialEffects/interface/EnergyLossUpdator.h
"
5
#include "
TrackingTools/GsfTracking/interface/GsfMaterialEffectsAdapter.h
"
6
#include "
TrackingTools/GsfTracking/interface/GsfMultipleScatteringUpdator.h
"
7
#include "
TrackingTools/GsfTracking/interface/GsfBetheHeitlerUpdator.h
"
8
#include "
TrackingTools/GsfTracking/interface/GsfCombinedMaterialEffectsUpdator.h
"
9
10
#include "
FWCore/Framework/interface/EventSetup.h
"
11
#include "
FWCore/Framework/interface/ESHandle.h
"
12
#include "
FWCore/Framework/interface/ModuleFactory.h
"
13
#include "
FWCore/Framework/interface/ESProducer.h
"
14
15
#include <string>
16
#include <memory>
17
18
using namespace
edm;
19
20
GsfMaterialEffectsESProducer::GsfMaterialEffectsESProducer
(
const
edm::ParameterSet
&
p
)
21
{
22
std::string
myname = p.
getParameter
<
std::string
>(
"ComponentName"
);
23
pset_ =
p
;
24
setWhatProduced(
this
,myname);
25
}
26
27
GsfMaterialEffectsESProducer::~GsfMaterialEffectsESProducer
() {}
28
29
boost::shared_ptr<GsfMaterialEffectsUpdator>
30
GsfMaterialEffectsESProducer::produce
(
const
TrackingComponentsRecord
& iRecord){
31
double
mass = pset_.getParameter<
double
>(
"Mass"
);
32
std::string
msName = pset_.getParameter<
std::string
>(
"MultipleScatteringUpdator"
);
33
std::string
elName = pset_.getParameter<
std::string
>(
"EnergyLossUpdator"
);
34
35
GsfMaterialEffectsUpdator
* msUpdator;
36
if
( msName ==
"GsfMultipleScatteringUpdator"
) {
37
msUpdator =
new
GsfMultipleScatteringUpdator
(mass);
38
}
39
else
{
40
msUpdator =
new
GsfMaterialEffectsAdapter(
MultipleScatteringUpdator
(mass));
41
}
42
43
GsfMaterialEffectsUpdator
* elUpdator;
44
if
( elName ==
"GsfBetheHeitlerUpdator"
) {
45
std::string
fileName
= pset_.getParameter<
std::string
>(
"BetheHeitlerParametrization"
);
46
int
correction = pset_.getParameter<
int
>(
"BetheHeitlerCorrection"
);
47
elUpdator =
new
GsfBetheHeitlerUpdator
(fileName,correction);
48
}
49
else
{
50
elUpdator =
new
GsfMaterialEffectsAdapter(
EnergyLossUpdator
(mass));
51
}
52
53
boost::shared_ptr<GsfMaterialEffectsUpdator> updator =
54
boost::shared_ptr<GsfMaterialEffectsUpdator>(
new
GsfCombinedMaterialEffectsUpdator(*msUpdator,
55
*elUpdator));
56
delete
msUpdator;
57
delete
elUpdator;
58
59
return
updator;
60
}
61
62
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
GsfMultipleScatteringUpdator
GsfMaterialEffectsUpdator
Definition:
GsfMaterialEffectsUpdator.h:17
EnergyLossUpdator
TrackingComponentsRecord
Definition:
TrackingComponentsRecord.h:13
EventSetup.h
MultipleScatteringUpdator
convertXMLtoSQLite_cfg.fileName
tuple fileName
Definition:
convertXMLtoSQLite_cfg.py:12
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:255
GsfBetheHeitlerUpdator
GsfMaterialEffectsESProducer::produce
boost::shared_ptr< GsfMaterialEffectsUpdator > produce(const TrackingComponentsRecord &)
Definition:
GsfMaterialEffectsESProducer.cc:30
ESHandle.h
GsfMaterialEffectsESProducer.h
GsfMultipleScatteringUpdator.h
GsfMaterialEffectsESProducer::GsfMaterialEffectsESProducer
GsfMaterialEffectsESProducer(const edm::ParameterSet &p)
Definition:
GsfMaterialEffectsESProducer.cc:20
EnergyLossUpdator.h
ESProducer.h
AlCaHLTBitMon_ParallelJobs.p
tuple p
Definition:
AlCaHLTBitMon_ParallelJobs.py:152
GsfMaterialEffectsESProducer::~GsfMaterialEffectsESProducer
virtual ~GsfMaterialEffectsESProducer()
Definition:
GsfMaterialEffectsESProducer.cc:27
GsfCombinedMaterialEffectsUpdator.h
GsfMaterialEffectsAdapter.h
edm::ParameterSet
Definition:
ParameterSet.h:35
ModuleFactory.h
GsfBetheHeitlerUpdator.h
MultipleScatteringUpdator.h
Generated for CMSSW Reference Manual by
1.8.5