ATLAS Offline Software
Loading...
Searching...
No Matches
L1CaloRxCoolChannelId.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef L1CALORXCOOLCHANNELID_H
6#define L1CALORXCOOLCHANNELID_H
7
8#include <ostream>
9
11 friend std::ostream& operator<<(std::ostream& output, const L1CaloRxCoolChannelId& r);
12
13public:
14
16 L1CaloRxCoolChannelId(unsigned int crate, unsigned int module, unsigned int inputConn, unsigned int inputPair);
17 L1CaloRxCoolChannelId(unsigned int crate, unsigned int module, unsigned int inputConn, unsigned int inputPair, unsigned int outputConn, unsigned int outputPair);
18 L1CaloRxCoolChannelId(unsigned int id);
21
22 unsigned int crate() const { return (unsigned int) m_id/1024; };
23 unsigned int module() const { return (unsigned int) m_id%1024/64; };
24 unsigned int inputConn() const { return (unsigned int) m_id%64/16; };
25 unsigned int inputPair() const { return (unsigned int) m_id%16; };
26
27 unsigned int id() const { return m_id; };
28
29 unsigned int outputConn() const;
30 unsigned int outputPair() const;
31
32 void outputAttributes(unsigned int conn, unsigned int pair);
33
35 bool operator==(const L1CaloRxCoolChannelId& id) const;
36 bool operator<(const L1CaloRxCoolChannelId& id) const;
37
38private:
39
40 void setId(unsigned int crate,
41 unsigned int module,
42 unsigned int inputConn,
43 unsigned int inputPair);
44
45 unsigned int m_id;
46
48 unsigned int m_outputConn;
49 unsigned int m_outputPair;
50
51};
52
53#endif
unsigned int outputPair() const
friend std::ostream & operator<<(std::ostream &output, const L1CaloRxCoolChannelId &r)
bool operator<(const L1CaloRxCoolChannelId &id) const
unsigned int id() const
void outputAttributes(unsigned int conn, unsigned int pair)
bool operator==(const L1CaloRxCoolChannelId &id) const
unsigned int module() const
~L1CaloRxCoolChannelId()=default
L1CaloRxCoolChannelId & operator=(const L1CaloRxCoolChannelId &id)=default
unsigned int inputConn() const
unsigned int inputPair() const
unsigned int outputConn() const
void setId(unsigned int crate, unsigned int module, unsigned int inputConn, unsigned int inputPair)
Set the CoolChannelId value from its component fields.
unsigned int crate() const
L1CaloRxCoolChannelId()
Create a L1CaloRxCoolChannelId from the integer ID field.
STL class.
int r
Definition globals.cxx:22