Back to home page

EIC code displayed by LXR

 
 

    


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

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/Detector/LayerStructureBuilder.hpp"
0012 #include "Acts/Detector/ProtoBinning.hpp"
0013 #include "Acts/Detector/interface/IDetectorComponentBuilder.hpp"
0014 #include "Acts/Detector/interface/IExternalStructureBuilder.hpp"
0015 #include "Acts/Detector/interface/IInternalStructureBuilder.hpp"
0016 #include "Acts/Geometry/GeometryContext.hpp"
0017 #include "Acts/Surfaces/Surface.hpp"
0018 #include "Acts/Utilities/Logger.hpp"
0019 
0020 #include <iostream>
0021 #include <string>
0022 #include <vector>
0023 
0024 namespace Acts::Experimental {
0025 
0026 class MultiWireStructureBuilder {
0027  public:
0028   /// @brief Configuration struct for the MultiWireStructure Builder
0029 
0030   struct Config {
0031     /// The name of the detector volume component
0032     std::string name = "";
0033 
0034     /// The surfaces of the Multi Wire
0035     std::vector<std::shared_ptr<Acts::Surface>> mlSurfaces = {};
0036 
0037     /// The transform of the Multi Wire
0038     Transform3 transform = Transform3::Identity();
0039 
0040     /// The bounds of the multi-wire volume
0041     std::vector<double> mlBounds = {};
0042 
0043     // The binning of the multi wire structure
0044     std::vector<ProtoBinning> mlBinning = {};
0045 
0046     /// A tolerance config
0047     float toleranceOverlap = 10.;
0048   };
0049 
0050   /// Constructor
0051   /// @param config The configure of the MultiWireStructureBuilder
0052   /// @param logger logging instance for screen output
0053 
0054   MultiWireStructureBuilder(
0055       const Config& config,
0056       std::unique_ptr<const Acts::Logger> logger = Acts::getDefaultLogger(
0057           "MultiWireStructureBuilder", Acts::Logging::VERBOSE));
0058 
0059   ~MultiWireStructureBuilder() = default;
0060 
0061   /// Construct the detector component
0062 
0063   /// @param gctx The Geometry Context of the current geometry
0064   /// @return a detector component object with the detector volume of the multilayer
0065 
0066   Acts::Experimental::DetectorComponent construct(
0067       const Acts::GeometryContext& gctx);
0068 
0069  private:
0070   Config mCfg;
0071 
0072   const Acts::Logger& logger() const { return *mLogger; }
0073 
0074   std::unique_ptr<const Acts::Logger> mLogger;
0075 };
0076 
0077 }  // namespace Acts::Experimental