CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
EcalPseudoStripInputDigi.cc
Go to the documentation of this file.
2 
3 
5 }
6 
8  size_(0), data_(MAXSAMPLES) {
9 }
10 
12 {
13  if (size_ == 1)
14  return 0;
15  else if (size_ == 5)
16  return 2;
17  else
18  return -1;
19 }
20 
23 {
24  int sample = sampleOfInterest();
25  if (sample != -1)
26  return data_[sample].pseudoStripInput();
27  else
28  return -1;
29 }
30 
33 {
34  int sample = sampleOfInterest();
35  if (sample != -1)
36  return data_[sample].fineGrain();
37  else
38  return false;
39 }
40 
42 {
43  if (size_ == 1)
44  return false;
45  else if (size_ > 1)
46  return true;
47  return false;
48 }
49 
51  if (size<0) size_=0;
52  else if (size>MAXSAMPLES) size_=MAXSAMPLES;
53  else size_=size;
54 }
55 
56 
57 std::ostream& operator<<(std::ostream& s, const EcalPseudoStripInputDigi& digi) {
58  s << digi.id() << " " << digi.size() << " samples " << std::endl;
59  for (int i=0; i<digi.size(); i++)
60  s << " " << digi.sample(i) << std::endl;
61  return s;
62 }
63 
int i
Definition: DBlmapReader.cc:9
const EcalTriggerElectronicsId & id() const
const EcalPseudoStripInputSample & sample(int i) const
std::ostream & operator<<(std::ostream &out, const ALILine &li)
Definition: ALILine.cc:188
int pseudoStripInput() const
get the encoded/compressed Et of interesting sample
bool fineGrain() const
get the fine-grain bit of interesting sample
std::vector< EcalPseudoStripInputSample > data_
int sampleOfInterest() const
Gets the interesting sample.
bool isDebug() const
True if debug mode (# of samples &gt; 1)
size_(0)
Definition: OwnArray.h:181
Ecal trigger electronics identification [32:20] Unused (so far) [19:13] TCC id [12:6] TT id [5:3] pse...
tuple size
Write out results.