ATLAS Offline Software
Loading...
Searching...
No Matches
EnumDef.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef ENUMDEF_H
6#define ENUMDEF_H
7
8#include <array>
9
10namespace MCP {
11
12 // This is for SagittaCorrection, there are two different types of error terms
13 enum class TrackType{ CB, ID, ME };
14
15 // This is for SagittaCorrection, there are two different types of error terms
17
18 // This for the calibration constants of the Scale and Resolution Corrections, s0/s1/r0/r1/r2
20
21 // Params
22 enum class ScaleSmearParam{ s0, s1, r0, r1, r2 };
23
24 // Params
25 enum class ExpectedResParam{ r0, r1, r2, r2tan2 };
26
27 // Data year
29
30 // For HighPtSmearing
32
33 // Data24 and Run4 are not supported yet
35
36 // Need this defined as a simple enum to not change any interface class
37 namespace DetectorType { enum { MS = 1, ID = 2, CB = 3 };}
38
39 inline std::string toString(TrackType trkType)
40 {
41 if(trkType == TrackType::CB) return "CB";
42 if(trkType == TrackType::ID) return "ID";
43 if(trkType == TrackType::ME) return "ME";
44
45 return "";
46 }
47
48 inline std::string toString(ScaleSmearParam param)
49 {
50 if(param == ScaleSmearParam::s0) return "s0";
51 if(param == ScaleSmearParam::s1) return "s1";
52 if(param == ScaleSmearParam::r0) return "r0";
53 if(param == ScaleSmearParam::r1) return "r1";
54 if(param == ScaleSmearParam::r2) return "r2";
55
56 return "";
57 }
58
59 inline std::string toString(DataYear year)
60 {
61 if(year == DataYear::Data16) return "Data16";
62 if(year == DataYear::Data17) return "Data17";
63 if(year == DataYear::Data18) return "Data18";
64 if(year == DataYear::Data22) return "Data22";
65 if(year == DataYear::Data23) return "Data23";
66 if(year == DataYear::Data24) return "Data24";
67 if(year == DataYear::Run4) return "Run4";
68 return "";
69 }
70
71 // Need this defined as a simple enum to not change any interface class
72 namespace SystVariation {
73 enum { Default = 0, Down = -1, Up = 1 };
74 }
75
76};
77
78#endif
std::string toString(TrackType trkType)
Definition EnumDef.h:39
DataYear
Definition EnumDef.h:28
ScaleResCorrection
Definition EnumDef.h:19
static constexpr std::array< MCP::DataYear, 7 > dataYearList
Definition EnumDef.h:34
SagittaCorrection
Definition EnumDef.h:16
MST_Categories
Definition EnumDef.h:31
ScaleSmearParam
Definition EnumDef.h:22
TrackType
Definition EnumDef.h:13
ExpectedResParam
Definition EnumDef.h:25