File indexing completed on 2024-04-06 12:02:40
0001 #include "CondFormats/SiStripObjects/interface/Phase2TrackerModule.h"
0002 #include <iostream>
0003 #include <sstream>
0004
0005 std::string Phase2TrackerModule::description(bool compact) const {
0006 std::stringstream ss;
0007 if (compact) {
0008 ss << "0x" << std::hex << getDetid() << " (" << (getModuleType() == Phase2TrackerModule::SS ? "2S" : "PS") << ") ";
0009 ss << "GBT 0x" << std::hex << getGbtid() << " FED " << std::dec << getCh().first << "." << getCh().second;
0010 ss << " C " << getCoolingLoop() << " P " << getPowerGroup() << std::endl;
0011 } else {
0012 ss << "Module of type " << (getModuleType() == Phase2TrackerModule::SS ? "2S" : "PS") << ":" << std::endl;
0013 ss << " Detid: 0x" << std::hex << getDetid() << " GBTid: 0x" << getGbtid() << std::endl;
0014 ss << " FED connection: " << std::dec << getCh().first << "." << getCh().second << std::endl;
0015 ss << " Cooling loop: " << getCoolingLoop() << std::endl;
0016 ss << " Power group: " << getPowerGroup() << std::endl;
0017 }
0018 return ss.str();
0019 }