CMS 3D CMS Logo

Functions
HOTriggerPrimitiveDigi.cc File Reference
#include "DataFormats/HcalDigi/interface/HOTriggerPrimitiveDigi.h"
#include "FWCore/MessageLogger/interface/MessageLogger.h"

Go to the source code of this file.

Functions

std::ostream & operator<< (std::ostream &s, const HOTriggerPrimitiveDigi &HOtpd)
 

Function Documentation

◆ operator<<()

std::ostream& operator<< ( std::ostream &  s,
const HOTriggerPrimitiveDigi HOtpd 
)

Definition at line 37 of file HOTriggerPrimitiveDigi.cc.

References triggerObjects_cff::bit, HOTriggerPrimitiveDigi::data(), HOTriggerPrimitiveDigi::ieta(), HOTriggerPrimitiveDigi::iphi(), HOTriggerPrimitiveDigi::nsamples(), alignCSCRings::s, and HOTriggerPrimitiveDigi::whichSampleTriggered().

37  {
38  s << "(HO TP " << HOtpd.ieta() << ", " << HOtpd.iphi() << ", ";
39  // s << HOtpd.whichSampleTriggered() << "_of_" << HOtpd.nsamples() << " [";
40  for (int bit = 0; bit < HOtpd.nsamples(); bit++) {
41  if (HOtpd.data(bit))
42  s << "1";
43  else
44  s << "0";
45  if (bit == HOtpd.whichSampleTriggered())
46  s << "* ";
47  else
48  s << " ";
49  }
50  s << " )";
51  return s;
52 }
int ieta() const
get the signed ieta value
int whichSampleTriggered() const
get the number of the triggering sample
int iphi() const
get the iphi value
bool data(int whichbit=HO_TP_SAMPLES_MAX) const
int nsamples() const
get the number of samples used to compute the TP