Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
LayerArrayCreator.hpp
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file LayerArrayCreator.hpp
1 // This file is part of the Acts project.
2 //
3 // Copyright (C) 2016-2018 CERN for the benefit of the Acts project
4 //
5 // This Source Code Form is subject to the terms of the Mozilla Public
6 // License, v. 2.0. If a copy of the MPL was not distributed with this
7 // file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 
9 #pragma once
10 
15 
16 #include <memory>
17 #include <utility>
18 
19 namespace Acts {
20 
21 class Surface;
22 class Layer;
23 
33 
35  public:
37  struct Config {};
38 
42  LayerArrayCreator(const Config& /*cfg*/,
43  std::unique_ptr<const Logger> logger =
44  getDefaultLogger("LayerArrayCreator", Logging::INFO))
45  : m_logger(std::move(logger)) {}
46 
48  ~LayerArrayCreator() override = default;
49 
60  std::unique_ptr<const LayerArray> layerArray(
61  const GeometryContext& gctx, const LayerVector& layersInput, double min,
62  double max, BinningType bType = arbitrary,
63  BinningValue bValue = binX) const override;
64 
66  void setLogger(std::unique_ptr<const Logger> logger) {
67  m_logger = std::move(logger);
68  }
69 
70  private:
72  const Logger& logger() const { return *m_logger; }
73 
75  std::unique_ptr<const Logger> m_logger = nullptr;
76 
84  std::shared_ptr<Surface> createNavigationSurface(const GeometryContext& gctx,
85  const Layer& layer,
86  BinningValue bValue,
87  double offset) const;
88 };
89 
90 } // namespace Acts