ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
MuonSpectrometer
MuonRDO
MuonRDO
TgcRdoIdHash.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 MUONRDO_TGCRDOIDHASH_H
6
#define MUONRDO_TGCRDOIDHASH_H
7
8
#include <map>
9
#include <vector>
10
#include <inttypes.h>
11
12
/*
13
Hash function for TGC RDO Identifier
14
@author Tadashi Maeno
15
based on RpcPadIdHash by Ketevi A. Assamagan
16
*/
17
class
TgcRdoIdHash
18
{
19
public
:
20
21
typedef
uint16_t
ID
;
22
23
TgcRdoIdHash
();
24
virtual
~TgcRdoIdHash
() {}
25
27
int
operator()
(
const
ID
&
id
)
const
;
28
30
int
max
()
const
{
return
m_size
;}
31
33
ID
identifier
(
int
i)
const
;
34
36
uint16_t
subDetectorId
(
int
i)
const
;
37
uint16_t
rodId
(
int
i)
const
;
38
39
// return value definition
40
enum
{
INVALID_ID
= 0xFFFF};
41
42
private
:
44
int
m_size
;
45
48
std::map<ID,int>
m_lookup
;
49
52
std::vector<ID>
m_int2id
;
53
56
std::vector<uint16_t>
m_int2subDetectorId
;
57
std::vector<uint16_t>
m_int2rodId
;
58
};
59
60
#endif
61
TgcRdoIdHash::m_int2id
std::vector< ID > m_int2id
reverse lookup
Definition
TgcRdoIdHash.h:52
TgcRdoIdHash::rodId
uint16_t rodId(int i) const
reverse conversion : ROD ID
Definition
TgcRdoIdHash.cxx:70
TgcRdoIdHash::max
int max() const
return maximum number of IDs
Definition
TgcRdoIdHash.h:30
TgcRdoIdHash::m_int2subDetectorId
std::vector< uint16_t > m_int2subDetectorId
reverse lookup for SubDetectorID and ROD ID
Definition
TgcRdoIdHash.h:56
TgcRdoIdHash::m_lookup
std::map< ID, int > m_lookup
lookup table
Definition
TgcRdoIdHash.h:48
TgcRdoIdHash::ID
uint16_t ID
Definition
TgcRdoIdHash.h:21
TgcRdoIdHash::TgcRdoIdHash
TgcRdoIdHash()
Definition
TgcRdoIdHash.cxx:9
TgcRdoIdHash::m_int2rodId
std::vector< uint16_t > m_int2rodId
Definition
TgcRdoIdHash.h:57
TgcRdoIdHash::operator()
int operator()(const ID &id) const
Convert ID to int.
Definition
TgcRdoIdHash.cxx:81
TgcRdoIdHash::m_size
int m_size
total number of IDs
Definition
TgcRdoIdHash.h:44
TgcRdoIdHash::subDetectorId
uint16_t subDetectorId(int i) const
reverse conversion for SubDetectorID and ROD ID
Definition
TgcRdoIdHash.cxx:59
TgcRdoIdHash::INVALID_ID
@ INVALID_ID
Definition
TgcRdoIdHash.h:40
TgcRdoIdHash::~TgcRdoIdHash
virtual ~TgcRdoIdHash()
Definition
TgcRdoIdHash.h:24
TgcRdoIdHash::identifier
ID identifier(int i) const
reverse conversion
Definition
TgcRdoIdHash.cxx:48
Generated on
for ATLAS Offline Software by
1.17.0