ATLAS Offline Software
Loading...
Searching...
No Matches
ArgStrToSizeT Class Reference

#include <ArgStrToSizeT.h>

Collaboration diagram for ArgStrToSizeT:

Public Member Functions

unsigned long long operator() (const std::string &s)

Detailed Description

Definition at line 13 of file ArgStrToSizeT.h.

Member Function Documentation

◆ operator()()

unsigned long long ArgStrToSizeT::operator() ( const std::string & s)
inline

Definition at line 16 of file ArgStrToSizeT.h.

16 {
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 }

The documentation for this class was generated from the following file: