 |
ATLAS Offline Software
|
Go to the documentation of this file.
12 int field = vmx - vmn + 1;
13 int nb = std::bit_width(
static_cast<unsigned>(
field - 1));
15 m_IDs.push_back(std::move(
id));
23 int vmx = (1 <<
nb) - 1;
25 m_IDs.push_back(std::move(
id));
32 for (
unsigned int i=0;
i<
m_IDs.size();
i++)
37 std::cout<<
"HitIdHelper: field "<<
name<<
": supplied value "<<
n<<
38 " is not within the allowed range ["<<
m_IDs[
i].vMin<<
","<<
m_IDs[
i].vMax
39 <<
"] : the result of this action is unpredictable "<<std::endl;
49 for (
unsigned int i=0;
i<
m_IDs.size();
i++)
57 std::cout<<
"HitIdHelper: field "<<
name<<
" not found: returning 0"<<
64 for (
unsigned int i=0;
i<
m_IDs.size();
i++)
66 std::cout<<
"-- Field "<<
m_IDs[
i].fieldName<<
"\t["<<
m_IDs[
i].vMin
68 <<
"\tfirst Bit "<<
m_IDs[
i].firstBit<<std::endl;
74 for (
unsigned int i=0;
i<8*
sizeof(
int);
i++)
76 if ((
id & (1
u<<
i))) std::cout<<
"1";
void SetFieldValue(const std::string &name, int n, HitID &targetID) const
void InitializeField(const std::string &n, int vmn, int vmx)
static void SetBit(int &i, int bitpos)
@ u
Enums for curvilinear frames.
static void Print(int id)
int GetFieldValue(const std::string &name, HitID targetID) const
static void Store(int &id, int value, int first, int field)
static void UnsetBit(int &i, int bitpos)
static int Retrieve(int id, int first, int field)