CMS 3D CMS Logo

EcalPseudoStripInputDigi.cc
Go to the documentation of this file.
2 
3 EcalPseudoStripInputDigi::EcalPseudoStripInputDigi() : size_(0), data_(MAXSAMPLES) {}
4 
6  : id_(id), size_(0), data_(MAXSAMPLES) {}
7 
9  if (size_ == 1)
10  return 0;
11  else if (size_ == 5)
12  return 2;
13  else
14  return -1;
15 }
16 
19  int sample = sampleOfInterest();
20  if (sample != -1)
21  return data_[sample].pseudoStripInput();
22  else
23  return -1;
24 }
25 
28  int sample = sampleOfInterest();
29  if (sample != -1)
30  return data_[sample].fineGrain();
31  else
32  return false;
33 }
34 
36  if (size_ == 1)
37  return false;
38  else if (size_ > 1)
39  return true;
40  return false;
41 }
42 
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:29
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