CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Functions
HcalZDCDetId.cc File Reference
#include "DataFormats/HcalDetId/interface/HcalZDCDetId.h"
#include "FWCore/Utilities/interface/Exception.h"

Go to the source code of this file.

Functions

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

Function Documentation

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

Definition at line 75 of file HcalZDCDetId.cc.

References HcalZDCDetId::EM, HcalZDCDetId::HAD, and HcalZDCDetId::LUM.

75  {
76  s << "(ZDC" << ((id.zside()==1)?("+"):("-"));
77  switch (id.section()) {
78  case(HcalZDCDetId::EM) : s << " EM "; break;
79  case(HcalZDCDetId::HAD) : s << " HAD "; break;
80  case(HcalZDCDetId::LUM) : s << " LUM "; break;
81  default : s <<" UNKNOWN ";
82  }
83  return s << id.channel() << "," << id.depth() << ')';
84 }