![]() |
|
|||
File indexing completed on 2025-10-22 07:51:45
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 #pragma once 0010 0011 #include "Acts/Definitions/Algebra.hpp" 0012 #include "Acts/Material/IVolumeMaterial.hpp" 0013 #include "Acts/Material/Material.hpp" 0014 #include "Acts/Utilities/BinUtility.hpp" 0015 0016 #include <iosfwd> 0017 0018 namespace Acts { 0019 0020 /// @class ProtoVolumeMaterial 0021 /// 0022 /// @brief proxy to VolumeMaterial hand over BinUtility 0023 /// 0024 /// The ProtoVolumeMaterial class acts as a proxy to the VolumeMaterial 0025 /// to mark the volume on which the material should be mapped on 0026 /// at construction time of the geometry and to hand over the granularity of 0027 /// of the material map with the bin Utility. 0028 0029 class ProtoVolumeMaterial : public IVolumeMaterial { 0030 public: 0031 /// Constructor without BinUtility - homogeneous material 0032 ProtoVolumeMaterial() = default; 0033 0034 /// Constructor with BinUtility - multidimensional material 0035 /// 0036 /// @param binUtility a BinUtility determining the granularity 0037 /// and binning of the material on the volume 0038 explicit ProtoVolumeMaterial(const BinUtility& binUtility); 0039 0040 /// Copy constructor 0041 /// 0042 /// @param vmproxy The source proxy 0043 ProtoVolumeMaterial(const ProtoVolumeMaterial& vmproxy) = default; 0044 0045 /// Copy move constructor 0046 /// 0047 /// @param vmproxy The source proxy 0048 ProtoVolumeMaterial(ProtoVolumeMaterial&& vmproxy) = default; 0049 0050 /// Destructor 0051 /// 0052 ~ProtoVolumeMaterial() override = default; 0053 0054 /// Return the BinUtility 0055 /// @return Const reference to the bin utility for this material 0056 const BinUtility& binUtility() const; 0057 0058 /// Assignment operator 0059 /// 0060 /// @param vmproxy The source proxy 0061 /// @return Reference to this material proxy for assignment chaining 0062 ProtoVolumeMaterial& operator=(const ProtoVolumeMaterial& vmproxy) = default; 0063 0064 /// Return the material 0065 /// @return The vacuum material (always the same as this is a proxy) 0066 const Material material(const Vector3& /*position*/) const final; 0067 0068 /// Output Method for std::ostream 0069 /// 0070 /// @param sl The outoput stream 0071 /// @return Reference to the output stream for method chaining 0072 std::ostream& toStream(std::ostream& sl) const final; 0073 0074 private: 0075 BinUtility m_binUtility; 0076 Material m_material = Material::Vacuum(); 0077 }; 0078 0079 inline const Acts::Material Acts::ProtoVolumeMaterial::material( 0080 const Acts::Vector3& /*position*/) const { 0081 return m_material; 0082 } 0083 0084 inline const Acts::BinUtility& Acts::ProtoVolumeMaterial::binUtility() const { 0085 return m_binUtility; 0086 } 0087 0088 } // namespace Acts
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
![]() ![]() |