Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-09-28 08:23:10

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/Units.hpp"
0012 #include "Acts/Utilities/Logger.hpp"
0013 #include "ActsExamples/DetectorCommons/Detector.hpp"
0014 
0015 #include <array>
0016 #include <memory>
0017 #include <vector>
0018 
0019 namespace Acts {
0020 class IMaterialDecorator;
0021 }  // namespace Acts
0022 
0023 namespace ActsExamples {
0024 
0025 class TelescopeDetector : public Detector {
0026  public:
0027   struct Config {
0028     std::vector<double> positions{{0, 30, 60, 120, 150, 180}};
0029     std::vector<double> stereos{{0, 0, 0, 0, 0, 0}};
0030     std::array<double, 2> offsets{{0, 0}};
0031     std::array<double, 2> bounds{{25, 100}};
0032     double thickness{80 * Acts::UnitConstants::um};
0033     int surfaceType{0};
0034     int binValue{2};
0035     std::shared_ptr<const Acts::IMaterialDecorator> materialDecorator;
0036     Acts::Logging::Level logLevel{Acts::Logging::WARNING};
0037   };
0038 
0039   explicit TelescopeDetector(const Config& cfg);
0040 
0041   std::unique_ptr<G4VUserDetectorConstruction> buildGeant4DetectorConstruction(
0042       const Geant4ConstructionOptions& options) const override;
0043 
0044  protected:
0045   struct NoBuildTag {};
0046   explicit TelescopeDetector(
0047       const Config& cfg, NoBuildTag /*unused*/);  // used for aligned version
0048 
0049  private:
0050   Config m_cfg;
0051 };
0052 
0053 }  // namespace ActsExamples