CMS 3D CMS Logo

HcalGenericDetId.h File Reference

#include <ostream>
#include "DataFormats/DetId/interface/DetId.h"
#include "DataFormats/HcalDetId/interface/HcalSubdetector.h"

Go to the source code of this file.

Classes

class  HcalGenericDetId
 
Author:
F.Ratnikov, UMd Generic HCAL detector ID suitable for all Hcal subdetectors
Id
HcalGenericDetId.h,v 1.7 2008/07/15 20:14:11 rofierzy Exp
More...

Functions

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


Function Documentation

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

Definition at line 74 of file HcalGenericDetId.cc.

References HcalGenericDetId::genericSubdet(), HcalGenericDetId::HcalGenBarrel, HcalGenericDetId::HcalGenCalibration, HcalGenericDetId::HcalGenCastor, HcalGenericDetId::HcalGenEndcap, HcalGenericDetId::HcalGenForward, HcalGenericDetId::HcalGenOuter, HcalGenericDetId::HcalGenTriggerTower, HcalGenericDetId::HcalGenZDC, and DetId::null().

00074                                                                  {
00075   if (id.null()) s << "(Null Id)";
00076   else 
00077     switch (id.genericSubdet()) {
00078     case HcalGenericDetId::HcalGenBarrel: 
00079     case HcalGenericDetId::HcalGenEndcap: 
00080     case HcalGenericDetId::HcalGenOuter: 
00081     case HcalGenericDetId::HcalGenForward: s << HcalDetId(id); break;
00082     case HcalGenericDetId::HcalGenTriggerTower: s << HcalTrigTowerDetId(id); break;
00083     case HcalGenericDetId::HcalGenZDC: s << HcalZDCDetId(id); break;
00084     case HcalGenericDetId::HcalGenCastor: s << HcalCastorDetId(id); break;
00085     case HcalGenericDetId::HcalGenCalibration: s << HcalCalibDetId(id); break;
00086     default: s << "(Hcal Unknown Id: 0x" << std::hex << id.rawId() << std::dec << ')';
00087     }
00088   return s;
00089 }


Generated on Tue Jun 9 17:52:07 2009 for CMSSW by  doxygen 1.5.4