ATLAS Offline Software
Trigger
TrigHypothesis
TrigHLTJetHypo
src
ArgStrToSizeT.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 TRIGHLTJETHYPO_ARGSTRINGTOSIZET_H
6
#define TRIGHLTJETHYPO_ARGSTRINGTOSIZET_H
7
8
#include <string>
9
#include <vector>
10
#include <algorithm>
11
#include <limits>
12
13
class
ArgStrToSizeT
{
14
public
:
15
16
unsigned
long
long
operator()
(
const
std::string&
s
){
17
18
static
const
std::array<std::string,4> posinf{
"inf"
,
"+inf"
,
"pinf"
,
"INF"
};
19
unsigned
long
long
val
{0};
20
if
(
std::find
(posinf.begin(), posinf.end(),
s
) != posinf.end()) {
21
val
=
std::numeric_limits<std::size_t>::max
();
22
}
23
else
{
24
val
= std::stoull(
s
);
25
}
26
27
return
val
;
28
}
29
};
30
31
#endif
python.SystemOfUnits.s
int s
Definition:
SystemOfUnits.py:131
find
std::string find(const std::string &s)
return a remapped string
Definition:
hcg.cxx:135
max
constexpr double max()
Definition:
ap_fixedTest.cxx:33
ArgStrToSizeT::operator()
unsigned long long operator()(const std::string &s)
Definition:
ArgStrToSizeT.h:16
Pythia8_RapidityOrderMPI.val
val
Definition:
Pythia8_RapidityOrderMPI.py:14
ArgStrToSizeT
Definition:
ArgStrToSizeT.h:13
Generated on Wed Jan 8 2025 21:06:50 for ATLAS Offline Software by
1.8.18