ATLAS Offline Software
Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef IdentifierStandAlone
6 #define IdentifierStandAlone
7 
8 // Not really sure why this is needed.
9 // If it isn't there, then we get
10 // error: 'Long64_t' does not name a type
11 // in Identifier.h, only I haven't changed that.
12 // Some dependancy isn't defined quite right.
13 #include <RtypesCore.h>
14 
15 class Identifier
16 {
17  public:
18  typedef Long64_t value_type;
19 
20  typedef enum bit_defs_enum
21  {
22  NBITS = sizeof(value_type) * 8, // bits per byte
23  MAX_BIT = (static_cast<value_type>(1) << (NBITS - 1)),
24  ALL_BITS = ~(static_cast<value_type>(0))
26 
27  typedef enum max_value_type_enum {
28  //max_value = 0xFFFFFFFFFFFFFFFFULL
29  max_value = ~(static_cast<value_type>(0))
31 
33  Identifier(const Identifier& value) = default;
35 
36  operator value_type() const { return m_id; }
37 
38  Identifier& operator = (const Identifier& old) = default;
40  bool operator == (const Identifier& other) const {return (m_id == other.m_id);}
41  bool operator != (const Identifier& other) const {return (m_id != other.m_id);}
42  bool operator < (const Identifier& other) const {return (m_id < other.m_id);}
43  bool operator > (const Identifier& other) const {return (m_id > other.m_id);}
44  bool operator <= (const Identifier& other) const {return (m_id <= other.m_id);}
45  bool operator >= (const Identifier& other) const {return (m_id >= other.m_id);}
46  bool operator == (Identifier::value_type other) const {return (m_id == other);}
47  bool operator != (Identifier::value_type other) const {return (m_id != other);}
48 
49  protected:
51 
52 };
53 
54 #endif
55 
Identifier::operator>
bool operator>(const Identifier &other) const
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h:43
Identifier::max_value
@ max_value
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:127
Identifier::max_value_type_enum
max_value_type_enum
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h:27
athena.value
value
Definition: athena.py:124
Identifier::Identifier
Identifier()
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h:32
Identifier::MAX_BIT
static constexpr value_type MAX_BIT
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:32
Identifier::m_id
value_type m_id
The only data member.
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:130
Identifier::Identifier
Identifier(value_type value)
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h:34
Identifier::operator>=
bool operator>=(const Identifier &other) const
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h:45
Identifier::bit_defs
enum Identifier::bit_defs_enum bit_defs
Identifier::operator=
Identifier & operator=(const Identifier32 &old)
Assignment operators overloads.
Identifier::ALL_BITS
static constexpr value_type ALL_BITS
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:33
Identifier::operator<
bool operator<(const Identifier &other) const
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h:42
Identifier::Identifier
Identifier(const Identifier &value)=default
Identifier::NBITS
static constexpr unsigned int NBITS
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:31
Identifier::value_type
Long64_t value_type
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h:18
Identifier::max_value_type
max_value_type
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:126
InDetDD::other
@ other
Definition: InDetDD_Defs.h:16
Identifier::operator!=
bool operator!=(const Identifier &other) const
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h:41
CSV_InDetExporter.old
old
Definition: CSV_InDetExporter.py:145
Identifier::operator<=
bool operator<=(const Identifier &other) const
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h:44
Identifier::operator==
bool operator==(const Identifier &other) const =default
Identifier::bit_defs_enum
bit_defs_enum
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/Identifier/Identifier.h:21
Identifier::value_type
unsigned long long value_type
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:27
value_type
Definition: EDM_MasterSearch.h:11
Identifier
Definition: IdentifierFieldParser.cxx:14