DataFormats
EcalDigi
src
EcalPseudoStripInputDigi.cc
Go to the documentation of this file.
1
#include "
DataFormats/EcalDigi/interface/EcalPseudoStripInputDigi.h
"
2
3
EcalPseudoStripInputDigi::EcalPseudoStripInputDigi
() : size_(0), data_(MAXSAMPLES) {}
4
5
EcalPseudoStripInputDigi::EcalPseudoStripInputDigi
(
const
EcalTriggerElectronicsId
&
id
)
6
: id_(
id
), size_(0), data_(MAXSAMPLES) {}
7
8
int
EcalPseudoStripInputDigi::sampleOfInterest
()
const
{
9
if
(
size_
== 1)
10
return
0;
11
else
if
(
size_
== 5)
12
return
2;
13
else
14
return
-1;
15
}
16
18
int
EcalPseudoStripInputDigi::pseudoStripInput
()
const
{
19
int
sample
=
sampleOfInterest
();
20
if
(
sample
!= -1)
21
return
data_
[
sample
].pseudoStripInput();
22
else
23
return
-1;
24
}
25
27
bool
EcalPseudoStripInputDigi::fineGrain
()
const
{
28
int
sample
=
sampleOfInterest
();
29
if
(
sample
!= -1)
30
return
data_
[
sample
].fineGrain();
31
else
32
return
false
;
33
}
34
35
bool
EcalPseudoStripInputDigi::isDebug
()
const
{
36
if
(
size_
== 1)
37
return
false
;
38
else
if
(
size_
> 1)
39
return
true
;
40
return
false
;
41
}
42
43
void
EcalPseudoStripInputDigi::setSize
(
int
size
) {
44
if
(
size
< 0)
45
size_
= 0;
46
else
if
(
size
>
MAXSAMPLES
)
47
size_
=
MAXSAMPLES
;
48
else
49
size_
=
size
;
50
}
51
52
std::ostream&
operator<<
(std::ostream&
s
,
const
EcalPseudoStripInputDigi
& digi) {
53
s
<< digi.
id
() <<
" "
<< digi.
size
() <<
" samples "
<< std::endl;
54
for
(
int
i
= 0;
i
< digi.
size
();
i
++)
55
s
<<
" "
<< digi.
sample
(
i
) << std::endl;
56
return
s
;
57
}
mps_fire.i
i
Definition:
mps_fire.py:428
EcalTriggerElectronicsId
Ecal trigger electronics identification [32:20] Unused (so far) [19:13] TCC id [12:6] TT id [5:3] pse...
Definition:
EcalTriggerElectronicsId.h:18
EcalPseudoStripInputDigi::sampleOfInterest
int sampleOfInterest() const
Gets the interesting sample.
Definition:
EcalPseudoStripInputDigi.cc:8
operator<<
std::ostream & operator<<(std::ostream &s, const EcalPseudoStripInputDigi &digi)
Definition:
EcalPseudoStripInputDigi.cc:52
EcalPseudoStripInputDigi
Definition:
EcalPseudoStripInputDigi.h:13
EcalPseudoStripInputDigi::id
const EcalTriggerElectronicsId & id() const
Definition:
EcalPseudoStripInputDigi.h:20
EcalPseudoStripInputDigi::data_
std::vector< EcalPseudoStripInputSample > data_
Definition:
EcalPseudoStripInputDigi.h:47
EcalPseudoStripInputDigi::isDebug
bool isDebug() const
True if debug mode (# of samples > 1)
Definition:
EcalPseudoStripInputDigi.cc:35
EcalPseudoStripInputDigi::setSize
void setSize(int size)
Definition:
EcalPseudoStripInputDigi.cc:43
alignCSCRings.s
s
Definition:
alignCSCRings.py:92
EcalPseudoStripInputDigi::sample
const EcalPseudoStripInputSample & sample(int i) const
Definition:
EcalPseudoStripInputDigi.h:24
EcalPseudoStripInputDigi::size
int size() const
Definition:
EcalPseudoStripInputDigi.h:21
EcalPseudoStripInputDigi::MAXSAMPLES
static const int MAXSAMPLES
Definition:
EcalPseudoStripInputDigi.h:30
EcalPseudoStripInputDigi::pseudoStripInput
int pseudoStripInput() const
get the encoded/compressed Et of interesting sample
Definition:
EcalPseudoStripInputDigi.cc:18
EcalPseudoStripInputDigi::fineGrain
bool fineGrain() const
get the fine-grain bit of interesting sample
Definition:
EcalPseudoStripInputDigi.cc:27
EcalPseudoStripInputDigi.h
triggerObjects_cff.id
id
Definition:
triggerObjects_cff.py:31
EcalPseudoStripInputDigi::size_
int size_
Definition:
EcalPseudoStripInputDigi.h:46
EcalPseudoStripInputDigi::EcalPseudoStripInputDigi
EcalPseudoStripInputDigi()
Definition:
EcalPseudoStripInputDigi.cc:3
findQualityFiles.size
size
Write out results.
Definition:
findQualityFiles.py:443
Generated for CMSSW Reference Manual by
1.8.16