ATLAS Offline Software
Control
AthenaKernel
src
StoreID.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3
*/
4
#include "
AthenaKernel/StoreID.h
"
5
#include <string>
6
#include <vector>
7
#include <utility>
8
9
static
const
std::vector<std::string> STORENAMES {
10
"StoreGateSvc"
,
11
"DetectorStore"
,
12
"ConditionStore"
,
13
"MetaDataStore"
,
14
"InputMetaDataStore"
,
15
"PileupStore"
,
16
"UnknownStore"
17
};
18
19
20
StoreID::type
21
StoreID::findStoreID
(
const
std::string& storeNamePrefix) {
22
// Account for AthenaMT stores that start with {digits}_
23
size_t
ist (0);
24
if
(::isdigit(storeNamePrefix.at(0))) {
25
ist = storeNamePrefix.find(
'_'
,0) +1;
26
}
27
//slightly faster
28
29
auto
c
(storeNamePrefix.at(ist));
30
switch
(
c
){
31
case
'C'
:
32
{
33
return
StoreID::CONDITION_STORE
;
34
break
;
35
}
36
case
'D'
:
37
{
38
return
StoreID::DETECTOR_STORE
;
39
break
;
40
}
41
case
'E'
:
42
{
43
return
StoreID::EVENT_STORE
;
44
break
;
45
}
46
case
'I'
:
47
{
48
return
StoreID::METADATA_STORE
;
49
break
;
50
}
51
case
'M'
:
52
{
53
return
StoreID::METADATA_STORE
;
54
break
;
55
}
56
case
'P'
:
57
{
58
return
StoreID::PILEUP_STORE
;
59
break
;
60
}
61
case
'S'
:
62
{
63
return
StoreID::EVENT_STORE
;
64
break
;
65
}
66
default
:
67
{
68
return
StoreID::UNKNOWN
;
69
break
;
70
}
71
}
72
73
return
StoreID::UNKNOWN
;
74
}
75
76
const
std::string&
77
StoreID::storeName
(
const
StoreID::type
&
id
) {
78
return
STORENAMES[ (
unsigned
int
)
id
];
79
}
80
CaloCellPos2Ntuple.int
int
Definition:
CaloCellPos2Ntuple.py:24
StoreID::CONDITION_STORE
@ CONDITION_STORE
Definition:
StoreID.h:28
StoreID::PILEUP_STORE
@ PILEUP_STORE
Definition:
StoreID.h:31
StoreID::METADATA_STORE
@ METADATA_STORE
Definition:
StoreID.h:29
StoreID::DETECTOR_STORE
@ DETECTOR_STORE
Definition:
StoreID.h:27
StoreID.h
StoreID::type
type
Definition:
StoreID.h:24
StoreID::UNKNOWN
@ UNKNOWN
Definition:
StoreID.h:32
StoreID::findStoreID
static StoreID::type findStoreID(const std::string &storeName)
Definition:
StoreID.cxx:21
StoreID::EVENT_STORE
@ EVENT_STORE
Definition:
StoreID.h:26
python.compressB64.c
def c
Definition:
compressB64.py:93
StoreID::storeName
static const std::string & storeName(const StoreID::type &s)
Definition:
StoreID.cxx:77
Generated on Sun Dec 22 2024 21:18:35 for ATLAS Offline Software by
1.8.18