48 unsigned int submodule,
56 this->
setId(crate, mType, moduleIndex, submodule,
channel);
92 unsigned int submodule,
96 (submodule & 0xff) << 8 | (
channel & 0xff);
101 m_id |= ((
unsigned int)mType & 0x0f) << 20;
122 unsigned int mTypeId = (
m_id & 0x00f00000) >> 20;
163 unsigned int logicalIndex = (
m_id & 0x000f0000) >> 16;
176 std::cout<<
"The physical position of module type: "<<mType.
toString()<<
" is not known. Returning the logical index instead !"<<std::endl;
186 std::cout<<
"The physical position of module type: "<<mType.
toString()<<
" is not known. Returning the logical index instead !"<<std::endl;
201 if (
this != &
id)
m_id =
id.m_id;
210 return m_id==
id.m_id;
214 output <<
"coolChannelId: 0x" << std::hex <<
r.id() << std::dec <<
"("<<
r.id()<<
"), crate: "<<
r.crate()<<
", module: "<<
r.module()<<
", submodule: "<<
r.subModule()<<
", channel: "<<
r.channel();
std::ostream & operator<<(std::ostream &output, const L1CaloCoolChannelId &r)
Encapsulates the ID of one channel of conditions data in COOL, ie the ID of a row in a table.
L1CaloModuleType moduleType() const
Return module type of this channel ID.
unsigned int physicalToLogicalModule(L1CaloModuleType mType, unsigned int module) const
L1CaloCoolChannelId & operator=(const L1CaloCoolChannelId &id)
Copy a L1CaloCoolChannelId.
bool operator==(const L1CaloCoolChannelId &id) const
bool operator<(const L1CaloCoolChannelId &id) const
L1CaloCoolChannelId()
Create a L1CaloCoolChannelId from the integer ID field.
unsigned int module(bool logical=true) const
Convert a typeId to a L1CaloModuleType.
unsigned int crate() const
void setId(unsigned int crate, L1CaloModuleType mType, unsigned int module, unsigned int submodule, unsigned int channel)
Set the CoolChannelId value from its component fields.
unsigned int logicalToPhysicalModule(L1CaloModuleType mType, unsigned int module) const
unsigned int channel() const
Infrastructure class encapsulating our known module types.
const std::string toString() const
Compare with type value.