Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:10:49

0001 // This file is part of the ACTS project.
0002 //
0003 // Copyright (C) 2016 CERN for the benefit of the ACTS project
0004 //
0005 // This Source Code Form is subject to the terms of the Mozilla Public
0006 // License, v. 2.0. If a copy of the MPL was not distributed with this
0007 // file, You can obtain one at https://mozilla.org/MPL/2.0/.
0008 
0009 #include <iostream>
0010 
0011 namespace Acts {
0012 
0013 inline float SpacePointMutableData::quality(const std::size_t idx) const {
0014   assert(idx < m_quality.size());
0015   return m_quality[idx];
0016 }
0017 
0018 inline float SpacePointMutableData::deltaR(const std::size_t idx) const {
0019   assert(idx < m_deltaR.size());
0020   return m_deltaR[idx];
0021 }
0022 
0023 inline void SpacePointMutableData::setQuality(const std::size_t idx,
0024                                               const float value) {
0025   assert(idx < m_quality.size());
0026   if (value > m_quality[idx]) {
0027     m_quality[idx] = value;
0028   }
0029 }
0030 
0031 inline void SpacePointMutableData::setDeltaR(const std::size_t idx,
0032                                              const float value) {
0033   assert(idx < m_deltaR.size());
0034   m_deltaR[idx] = value;
0035 }
0036 
0037 inline void SpacePointMutableData::resize(const std::size_t n) {
0038   clear();
0039   m_quality.resize(n, -std::numeric_limits<float>::infinity());
0040   m_deltaR.resize(n, 0.f);
0041 }
0042 
0043 inline void SpacePointMutableData::clear() {
0044   m_quality.clear();
0045   m_deltaR.clear();
0046 }
0047 
0048 }  // namespace Acts