LDMX Software
EcalAbstractID.cxx
2
3#include <iomanip>
4
5#include "DetDescr/EcalID.h"
7
8namespace ldmx {
9
10std::ostream& operator<<(std::ostream& s, const ldmx::EcalAbstractID& id) {
11 switch (id.cellType()) {
12 case (ldmx::EcalAbstractID::PrecisionGlobal):
13 return s << ldmx::EcalID(id);
14 case (ldmx::EcalAbstractID::TriggerCell):
15 return s << ldmx::EcalTriggerID(id);
16 default:
17 return s << "EcalAbstractID(" << id.cellType() << ":0x"
18 << std::setfill('0') << std::setw(6) << std::right << std::hex
19 << id.payload();
20 }
21}
22
23} // namespace ldmx
Class that serves as a parent for ECal detector IDs of various types.
Class that defines an ECal detector ID with a cell number.
Class that defines an ECal trigger cell detector ID.
Parent of precision and trigger EcalIDs.
Extension of DetectorID providing access to ECal layers and cell numbers in a hex grid.
Definition EcalID.h:20
Extension of DetectorID providing access to ECal trigger cell information.