Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
LineSurface.hpp
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file LineSurface.hpp
1 // This file is part of the Acts project.
2 //
3 // Copyright (C) 2016-2020 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
22 
23 #include <memory>
24 #include <string>
25 
26 namespace Acts {
27 
28 class LineBounds;
29 class DetectorElementBase;
30 class SurfaceBounds;
31 
41 class LineSurface : public Surface {
42 #ifndef DOXYGEN
43  friend Surface;
44 #endif
45 
46  protected:
53  LineSurface(const Transform3& transform, double radius, double halez);
54 
62  std::shared_ptr<const LineBounds> lbounds = nullptr);
63 
68  LineSurface(std::shared_ptr<const LineBounds> lbounds,
69  const DetectorElementBase& detelement);
70 
74  LineSurface(const LineSurface& other);
75 
81  LineSurface(const GeometryContext& gctx, const LineSurface& other,
82  const Transform3& shift);
83 
84  public:
85  ~LineSurface() override = default;
86  LineSurface() = delete;
87 
91  LineSurface& operator=(const LineSurface& other);
92 
100  const Vector2& lposition) const final;
101 
103  using Surface::normal;
104 
113  BinningValue bValue) const final;
114 
128  const Vector3& position,
129  const Vector3& direction) const final;
130 
139  const GeometryContext& gctx, const BoundVector& boundParams) const final;
140 
149  const GeometryContext& gctx, const FreeVector& parameters) const final;
150 
161  Vector3 localToGlobal(const GeometryContext& gctx, const Vector2& lposition,
162  const Vector3& direction) const final;
163 
196  const GeometryContext& gctx, const Vector3& position,
197  const Vector3& direction,
198  double tolerance = s_onSurfaceTolerance) const final;
199 
254  const GeometryContext& gctx, const Vector3& position,
255  const Vector3& direction, const BoundaryCheck& bcheck = false,
257 
263  double pathCorrection(const GeometryContext& gctx, const Vector3& position,
264  const Vector3& direction) const override;
265 
267  const SurfaceBounds& bounds() const final;
268 
270  std::string name() const override;
271 
282  const GeometryContext& gctx, const FreeVector& parameters) const final;
283 
293  const GeometryContext& gctx, const Vector3& position) const final;
294 
295  Vector3 lineDirection(const GeometryContext& gctx) const;
296 
297  protected:
299 
300  private:
307  bool globalToLocalPlain(const GeometryContext& gctx, const Vector3& position,
308  const Vector3& direction, Vector2& lposition) const;
309 };
310 
311 } // namespace Acts