Main Page
Namespaces
Classes
Package Documentation
TauAnalysis
MCEmbeddingTools
plugins
TrackerCleaner.cc
Go to the documentation of this file.
1
#include "
TauAnalysis/MCEmbeddingTools/plugins/TrackerCleaner.h
"
2
3
#include "
DataFormats/TrackerRecHit2D/interface/SiStripRecHit1D.h
"
4
#include "
DataFormats/TrackerRecHit2D/interface/SiStripRecHit2D.h
"
5
#include "
DataFormats/TrackerRecHit2D/interface/SiStripMatchedRecHit2D.h
"
6
#include "
DataFormats/TrackerRecHit2D/interface/ProjectedSiStripRecHit2D.h
"
7
8
#include "
DataFormats/TrackerRecHit2D/interface/SiPixelRecHit.h
"
9
#include "
DataFormats/SiPixelCluster/interface/SiPixelCluster.h
"
10
11
12
13
14
typedef
TrackerCleaner<SiPixelCluster>
PixelColCleaner
;
15
typedef
TrackerCleaner<SiStripCluster>
StripColCleaner
;
16
17
18
//-------------------------------------------------------------------------------
19
// define 'buildRecHit' functions used for different types of recHits
20
//-------------------------------------------------------------------------------
21
22
23
template
<
typename
T>
24
bool
TrackerCleaner<T>::match_rechit_type
(
const
TrackingRecHit
&murechit){
25
26
assert(0);
// CV: make sure general function never gets called;
27
// always use template specializations
28
return
false
;
29
30
}
31
32
33
template
<>
34
bool
TrackerCleaner<SiStripCluster>::match_rechit_type
(
const
TrackingRecHit
&murechit){
35
36
const
std::type_info &hit_type =
typeid
(murechit);
37
if
(hit_type ==
typeid
(
SiStripRecHit2D
))
return
true
;
38
else
if
(hit_type ==
typeid
(
SiStripRecHit1D
))
return
true
;
39
else
if
(hit_type ==
typeid
(
SiStripMatchedRecHit2D
))
return
true
;
40
else
if
(hit_type ==
typeid
(
ProjectedSiStripRecHit2D
))
return
true
;
41
42
43
44
return
false
;
45
46
}
47
48
template
<>
49
bool
TrackerCleaner<SiPixelCluster>::match_rechit_type
(
const
TrackingRecHit
&murechit){
50
51
52
const
std::type_info &hit_type =
typeid
(murechit);
53
if
(hit_type ==
typeid
(
SiPixelRecHit
))
return
true
;
54
55
return
false
;
56
57
}
58
59
60
DEFINE_FWK_MODULE
(
PixelColCleaner
);
61
DEFINE_FWK_MODULE
(
StripColCleaner
);
62
63
64
TrackerCleaner
Definition:
TrackerCleaner.h:40
SiStripRecHit1D.h
ProjectedSiStripRecHit2D.h
DEFINE_FWK_MODULE
#define DEFINE_FWK_MODULE(type)
Definition:
MakerMacros.h:17
SiPixelRecHit.h
SiStripRecHit2D
Definition:
SiStripRecHit2D.h:8
PixelColCleaner
TrackerCleaner< SiPixelCluster > PixelColCleaner
Definition:
TrackerCleaner.cc:14
TrackingRecHit
Definition:
TrackingRecHit.h:23
SiStripRecHit2D.h
SiStripMatchedRecHit2D
Definition:
SiStripMatchedRecHit2D.h:8
TrackerCleaner.h
SiStripMatchedRecHit2D.h
StripColCleaner
TrackerCleaner< SiStripCluster > StripColCleaner
Definition:
TrackerCleaner.cc:15
SiStripRecHit1D
Definition:
SiStripRecHit1D.h:11
ProjectedSiStripRecHit2D
Definition:
ProjectedSiStripRecHit2D.h:8
TrackerCleaner::match_rechit_type
bool match_rechit_type(const TrackingRecHit &murechit)
Definition:
TrackerCleaner.cc:24
SiPixelCluster.h
SiPixelRecHit
Our base class.
Definition:
SiPixelRecHit.h:23
Generated for CMSSW Reference Manual by
1.8.11