RecoLocalMuon
CSCRecHitD
src
CSCRangeMapForRecHit.cc
Go to the documentation of this file.
1
6
#include <
RecoLocalMuon/CSCRecHitD/src/CSCRangeMapForRecHit.h
>
7
8
CSCRangeMapForRecHit::CSCRangeMapForRecHit
() {}
9
10
CSCRangeMapForRecHit::~CSCRangeMapForRecHit
() {}
11
12
std::pair<CSCDetId, CSCDetIdSameChamberCompare>
CSCRangeMapForRecHit::cscChamber
(
CSCDetId
id
) {
13
return
std::make_pair(
id
,
CSCDetIdSameChamberCompare
());
14
}
15
16
std::pair<CSCDetId, CSCDetIdSameDetLayerCompare>
CSCRangeMapForRecHit::cscDetLayer
(
CSCDetId
id
) {
17
return
std::make_pair(
id
,
CSCDetIdSameDetLayerCompare
());
18
}
19
20
bool
CSCDetIdSameChamberCompare::operator()
(
CSCDetId
i1
,
CSCDetId
i2
)
const
{
21
if
(
i1
.chamberId() ==
i2
.chamberId())
22
return
false
;
// this removes layer bit and then uses DetId::op==
23
return
(
i1
<
i2
);
24
}
25
26
bool
CSCDetIdSameDetLayerCompare::operator()
(
CSCDetId
i1
,
CSCDetId
i2
)
const
{
27
if
(
i1
==
i2
)
28
return
false
;
// use DetId::op==
29
return
(
i1
<
i2
);
30
}
CSCDetIdSameChamberCompare::operator()
bool operator()(CSCDetId i1, CSCDetId i2) const
Definition:
CSCRangeMapForRecHit.cc:20
testProducerWithPsetDescEmpty_cfi.i2
i2
Definition:
testProducerWithPsetDescEmpty_cfi.py:46
testProducerWithPsetDescEmpty_cfi.i1
i1
Definition:
testProducerWithPsetDescEmpty_cfi.py:45
CSCRangeMapForRecHit::cscDetLayer
static std::pair< CSCDetId, CSCDetIdSameDetLayerCompare > cscDetLayer(CSCDetId id)
Definition:
CSCRangeMapForRecHit.cc:16
CSCDetIdSameDetLayerCompare::operator()
bool operator()(CSCDetId i1, CSCDetId i2) const
Definition:
CSCRangeMapForRecHit.cc:26
CSCRangeMapForRecHit.h
CSCRangeMapForRecHit::CSCRangeMapForRecHit
CSCRangeMapForRecHit()
Constructor.
Definition:
CSCRangeMapForRecHit.cc:8
CSCDetId
Definition:
CSCDetId.h:26
CSCDetIdSameChamberCompare
Definition:
CSCRangeMapForRecHit.h:17
CSCRangeMapForRecHit::~CSCRangeMapForRecHit
virtual ~CSCRangeMapForRecHit()
Destructor.
Definition:
CSCRangeMapForRecHit.cc:10
CSCRangeMapForRecHit::cscChamber
static std::pair< CSCDetId, CSCDetIdSameChamberCompare > cscChamber(CSCDetId id)
Returns a valid DetId + a valid comparator for the RangeMap.
Definition:
CSCRangeMapForRecHit.cc:12
CSCDetIdSameDetLayerCompare
Definition:
CSCRangeMapForRecHit.h:12
Generated for CMSSW Reference Manual by
1.8.16