Warning, file /include/Acts/Geometry/GeometryObject.hpp was not indexed
or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001
0002
0003
0004
0005
0006
0007
0008
0009 #pragma once
0010
0011 #include "Acts/Definitions/Algebra.hpp"
0012 #include "Acts/Geometry/GeometryContext.hpp"
0013 #include "Acts/Geometry/GeometryIdentifier.hpp"
0014 #include "Acts/Geometry/Polyhedron.hpp"
0015 #include "Acts/Utilities/BinningType.hpp"
0016 #include "Acts/Utilities/VectorHelpers.hpp"
0017
0018 namespace Acts {
0019
0020
0021
0022
0023
0024
0025
0026 class GeometryObject {
0027 public:
0028
0029 GeometryObject() = default;
0030
0031
0032 GeometryObject(const GeometryObject&) = default;
0033
0034
0035
0036
0037 GeometryObject(const GeometryIdentifier& geometryId)
0038 : m_geometryId(geometryId) {}
0039
0040
0041
0042
0043 GeometryObject& operator=(const GeometryObject& geometryId) {
0044 if (&geometryId != this) {
0045 m_geometryId = geometryId.m_geometryId;
0046 }
0047 return *this;
0048 }
0049
0050
0051 const GeometryIdentifier& geometryId() const;
0052
0053
0054
0055
0056
0057
0058
0059 virtual Vector3 binningPosition(const GeometryContext& gctx,
0060 BinningValue bValue) const = 0;
0061
0062
0063
0064
0065
0066
0067
0068 virtual double binningPositionValue(const GeometryContext& gctx,
0069 BinningValue bValue) const;
0070
0071
0072
0073
0074 void assignGeometryId(const GeometryIdentifier& geometryId);
0075
0076 protected:
0077 GeometryIdentifier m_geometryId;
0078 };
0079
0080 inline const GeometryIdentifier& GeometryObject::geometryId() const {
0081 return m_geometryId;
0082 }
0083
0084 inline void GeometryObject::assignGeometryId(
0085 const GeometryIdentifier& geometryId) {
0086 m_geometryId = geometryId;
0087 }
0088
0089 inline double GeometryObject::binningPositionValue(const GeometryContext& gctx,
0090 BinningValue bValue) const {
0091 return VectorHelpers::cast(binningPosition(gctx, bValue), bValue);
0092 }
0093
0094 }