CMS 3D CMS Logo

Classes | Functions
HcalZDCDetId.h File Reference
#include <ostream>
#include "DataFormats/DetId/interface/DetId.h"

Go to the source code of this file.

Classes

class  HcalZDCDetId
 

Functions

std::ostream & operator<< (std::ostream &, const HcalZDCDetId &id)
 

Function Documentation

◆ operator<<()

std::ostream& operator<< ( std::ostream &  ,
const HcalZDCDetId id 
)

Definition at line 107 of file HcalZDCDetId.cc.

References HcalZDCDetId::EM, HcalZDCDetId::HAD, HcalZDCDetId::LUM, HcalZDCDetId::RPD, alignCSCRings::s, and hgcalPlots::section.

107  {
108  s << "(ZDC" << ((id.zside() == 1) ? ("+") : ("-"));
109  switch (id.section()) {
110  case (HcalZDCDetId::EM):
111  s << " EM ";
112  break;
113  case (HcalZDCDetId::HAD):
114  s << " HAD ";
115  break;
116  case (HcalZDCDetId::LUM):
117  s << " LUM ";
118  break;
119  case (HcalZDCDetId::RPD):
120  s << " RPD ";
121  break;
122  default:
123  s << " UNKNOWN ";
124  }
125  return s << id.channel() << "," << id.depth() << ')';
126 }