ATLAS Offline Software
Loading...
Searching...
No Matches
PixelChargeCalibCondData.cxx File Reference
#include "PixelConditionsData/PixelChargeCalibCondData.h"
#include "PixelConditionsData/ChargeCalibrationBundle.h"
#include "PixelConditionsData/PixelModuleData.h"
#include <stdexcept>
#include <sstream>
#include <cfloat>
Include dependency graph for PixelChargeCalibCondData.cxx:

Go to the source code of this file.

Functions

template<typename T>
constexpr std::size_t enum2uint (T n, std::string_view callingFunctionName="")
 Convert an enum class to size_t for use as an array index.

Function Documentation

◆ enum2uint()

template<typename T>
std::size_t InDetDD::enum2uint ( T n,
std::string_view callingFunctionName = "" )
constexpr

Convert an enum class to size_t for use as an array index.

Definition at line 51 of file PixelReadoutDefinitions.h.

51 {
52 if (n==T::NONE){
53 throw std::out_of_range(std::format("{} InDetDD::enum2uint: 'NONE' type is out of range for {}", callingFunctionName, typeid(T).name()));
54 }
55 return static_cast<size_t>(n);
56 }