test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HcalTriggerPrimitiveDigi.cc
Go to the documentation of this file.
2 
3 
5 }
7  size_(0), hcalPresamples_(0) {
8 }
9 
11  if (size<0) size_=0;
12  else if (size>MAXSAMPLES) size_=MAXSAMPLES;
13  else size_=size;
14 }
16  if (ps<0) hcalPresamples_&=0xFFFFFF0;
17  // else if (ps>=size_) hcalPresamples_=size_-1;
18  else hcalPresamples_|=ps&0xF;
19 }
20 
21 void HcalTriggerPrimitiveDigi::setZSInfo(bool unsuppressed, bool markAndPass) {
22  if (markAndPass) hcalPresamples_|=0x10;
23  if (unsuppressed) hcalPresamples_|=0x20;
24 }
25 
26 std::ostream& operator<<(std::ostream& s, const HcalTriggerPrimitiveDigi& digi) {
27  s << digi.id() << " " << digi.size() << " samples "<< digi.presamples() << " presamples";
28  if (digi.zsUnsuppressed()) s << " zsUS";
29  if (digi.zsMarkAndPass()) s << " zsM&P";
30  s << std::endl;
31  for (int i=0; i<digi.size(); i++)
32  s << " " << digi.sample(i) << std::endl;
33  return s;
34 }
35 
36 
int i
Definition: DBlmapReader.cc:9
void setZSInfo(bool unsuppressed, bool markAndPass)
bool zsMarkAndPass() const
was ZS MarkAndPass?
std::ostream & operator<<(std::ostream &out, const ALILine &li)
Definition: ALILine.cc:187
bool zsUnsuppressed() const
was ZS unsuppressed?
const HcalTriggerPrimitiveSample & sample(int i) const
size_(0)
Definition: OwnArray.h:181
tuple size
Write out results.
const HcalTrigTowerDetId & id() const