|
ATLAS Offline Software
|
Go to the documentation of this file.
11 #ifndef IChargeCalibrationParser_h
12 #define IChargeCalibrationParser_h
16 #include <nlohmann/json.hpp>
18 #include "Identifier/Identifier.h"
24 #include <type_traits>
57 template<
typename T,
typename b = std::is_
integral<T>>
58 std::function<T(
size_t)>
60 auto f = [&
data](
size_t i)->T {
68 std::function<T(
size_t)>
70 auto f = [&
data](
size_t i)->T {
71 return data[
i].get<T>();
This is an Identifier helper class for the Pixel subdetector. This class is a factory for creating co...
char data[hepevt_bytes_allocation_ATLAS]
IChargeCalibrationParser(const PixelModuleData *pModData, const InDetDD::SiDetectorElementCollection *pElements, const PixelID *pId)
std::function< T(size_t)> getFunc(const std::vector< std::string > &data)
Return function converting a string to number type T at index i of data vector.
virtual ~IChargeCalibrationParser()=default
virtual ChargeCalibrationBundle parseImpl(unsigned int, const nlohmann::json &, int)=0
virtual ChargeCalibrationBundle parseImpl(unsigned int, const std::string &)=0
std::function< T(size_t)> getFunc(const nlohmann::json &data)
Return function converting an item to number type T at index i of json data.
ChargeCalibrationBundle parse(unsigned int hash, const T &data)
Struct for holding vectors of charge calibration constants, with utility methods.
const PixelModuleData * m_configData
virtual ChargeCalibrationBundle parseImpl(unsigned int, const nlohmann::json &)=0
static constexpr float m_chargeLimit
If the calculated charge exceeds this limit, a linear extrapolation is used at this point.
ChargeCalibrationBundle parse(unsigned int hash, const T &data, int inputSource)
const InDetDD::SiDetectorElementCollection * m_elements
const PixelID * m_pixelID
bundles of parameters used together in the PixelChargeCalibCondAlg