#include <MdtCalibDataContainer.h>
Definition at line 27 of file MdtCalibDataContainer.h.
◆ CorrectionPtr
◆ RtRelationPtr
◆ TubeContainerPtr
◆ RegionGranularity
| Enumerator |
|---|
| OneRt | |
| OnePerChamber | |
| OnePerMultiLayer | |
Definition at line 33 of file MdtCalibDataContainer.h.
33{ OneRt, OnePerChamber, OnePerMultiLayer };
◆ MdtCalibDataContainer()
Definition at line 13 of file MdtCalibDataContainer.cxx.
14 :
17}
const RegionGranularity m_granularity
const Muon::IMuonIdHelperSvc * m_idHelperSvc
RegionGranularity granularity() const
◆ ~MdtCalibDataContainer()
| MuonCalib::MdtCalibDataContainer::~MdtCalibDataContainer |
( |
| ) |
|
|
default |
◆ containerIndex()
| std::optional< unsigned int > MuonCalib::MdtCalibDataContainer::containerIndex |
( |
const Identifier & | measId, |
|
|
MsgStream & | msg ) const |
|
inlineprivate |
Definition at line 22 of file MdtCalibDataContainer.cxx.
22 {
23 IdentifierHash
hash{0};
24
26 (
m_idHelper.get_detectorElement_hash(measId, hash) ||
27 m_idHelper.detectorElement_hash_max() <
static_cast<unsigned int>(hash))) {
28 msg<<MSG::ERROR <<__FILE__<<
":"<<__LINE__<<
" Failed to look up a proper detector element hash for "
30 return std::nullopt;
31 }
else if (
m_granularity == RegionGranularity::OnePerChamber &&
33 m_idHelper.module_hash_max() <
static_cast<unsigned int>(hash))) {
34 msg<<MSG::ERROR <<__FILE__<<
":"<<__LINE__<<
" Failed to look up a proper detector element hash for "
36 return std::nullopt;
37 }
38 return std::make_optional<unsigned int>(static_cast<unsigned int>(hash));
39}
const MdtIdHelper & m_idHelper
◆ getCalibData()
Returns the calibration data associated with this station.
Definition at line 46 of file MdtCalibDataContainer.cxx.
46 {
48 if (!index) return nullptr;
52 }
53 msg<<MSG::WARNING<<__FILE__<<
":"<<__LINE__<<
" No Mdt calibration data is stored for "
55 return nullptr;
56}
char data[hepevt_bytes_allocation_ATLAS]
std::optional< unsigned int > containerIndex(const Identifier &measId, MsgStream &msg) const
std::vector< MdtFullCalibData > m_dataCache
◆ granularity()
◆ hasDataForChannel()
| bool MuonCalib::MdtCalibDataContainer::hasDataForChannel |
( |
const Identifier & | measId, |
|
|
MsgStream & | msg ) const |
◆ inversePropSpeed()
| float MuonCalib::MdtCalibDataContainer::inversePropSpeed |
( |
| ) |
const |
◆ setInversePropSpeed()
| void MuonCalib::MdtCalibDataContainer::setInversePropSpeed |
( |
const float | speed | ) |
|
◆ storeData() [1/3]
| bool MuonCalib::MdtCalibDataContainer::storeData |
( |
const Identifier & | mlID, |
|
|
CorrectionPtr | corrFuncSet, |
|
|
MsgStream & | msg ) |
Check for a valid index
Resize the container if neccessary
Definition at line 57 of file MdtCalibDataContainer.cxx.
57 {
60 if (!index) return false;
61 if (!corrFuncSet) {
62 msg << MSG::ERROR<<__FILE__<<
":"<<__LINE__<<
" No correction functional set parsed for multilayer "
64 return false;
65 }
69 if (cache.corrections && cache.corrections != corrFuncSet) {
70 msg << MSG::ERROR<<__FILE__<<
":"<<__LINE__<<
" There already exist a rt relation object for multilayer "
72 return false;
73 }
74 cache.corrections = std::move(corrFuncSet);
75
76 if (
msg.level() <= MSG::DEBUG) {
77 msg << MSG::DEBUG<<__FILE__<<
":"<<__LINE__<<
" Added successfully the rt corrections for "
79 }
80 return true;
81}
◆ storeData() [2/3]
| bool MuonCalib::MdtCalibDataContainer::storeData |
( |
const Identifier & | mlID, |
|
|
RtRelationPtr | rtRelation, |
|
|
MsgStream & | msg ) |
Check for a valid index
Resize the container if neccessary
Definition at line 82 of file MdtCalibDataContainer.cxx.
82 {
85 if (!index) return false;
86 if (!rtRelation) {
87 msg << MSG::ERROR<<__FILE__<<
":"<<__LINE__<<
" No rt relation parsed for multilayer "
89 return false;
90 }
94 if (cache.rtRelation && cache.rtRelation != rtRelation) {
95 msg << MSG::ERROR<<__FILE__<<
":"<<__LINE__<<
" There already exist a rt relation object for multilayer "
97 return false;
98 }
99 cache.rtRelation = std::move(rtRelation);
100
101 if (
msg.level() <= MSG::DEBUG) {
102 msg << MSG::DEBUG<<__FILE__<<
":"<<__LINE__<<
" Added successfully the rt relations for "
104 }
105 return true;
106}
◆ storeData() [3/3]
Check for a valid index
Resize the container if neccessary
Definition at line 107 of file MdtCalibDataContainer.cxx.
107 {
110 if (!index) return false;
111 if (!tubeContainer) {
112 msg << MSG::ERROR<<__FILE__<<
":"<<__LINE__<<
" No tube ontainer parsed for multilayer "
114 return false;
115 }
116
120 if (cache.tubeCalib && cache.tubeCalib != tubeContainer) {
121 msg << MSG::ERROR<<__FILE__<<
":"<<__LINE__<<
" There already exist a tube calibration container for multilayer "
123 return false;
124 }
125 if (
msg.level() <= MSG::DEBUG) {
126 msg << MSG::DEBUG<<__FILE__<<
":"<<__LINE__<<
" Added successfully the tube calibrations for "
128 }
129 cache.tubeCalib = tubeContainer;
132 m_idHelper.numberOfMultilayers(mlID) == 1)
return true;
134}
bool storeData(const Identifier &mlID, CorrectionPtr corrFuncSet, MsgStream &msg)
◆ m_dataCache
◆ m_granularity
| const RegionGranularity MuonCalib::MdtCalibDataContainer::m_granularity {RegionGranularity::OneRt} |
|
private |
◆ m_idHelper
◆ m_idHelperSvc
◆ m_invPropSpeed
| float MuonCalib::MdtCalibDataContainer::m_invPropSpeed {0.f} |
|
private |
The documentation for this class was generated from the following files: