File indexing completed on 2024-04-06 12:31:27
0001 #ifndef DetLayers_GeometricSearchDet_h
0002 #define DetLayers_GeometricSearchDet_h
0003
0004 #include "Geometry/CommonDetUnit/interface/GeomDet.h"
0005 #include "DataFormats/GeometrySurface/interface/BoundSurface.h"
0006
0007 #include "TrackingTools/DetLayers/interface/DetGroup.h"
0008 #include "DataFormats/GeometrySurface/interface/Surface.h"
0009 #include "TrackingTools/DetLayers/interface/GeomDetCompatibilityChecker.h"
0010
0011 #include "TrackingTools/GeomPropagators/interface/Propagator.h"
0012
0013 #include <vector>
0014
0015 class MeasurementEstimator;
0016
0017 class GeometricSearchDet {
0018 public:
0019 typedef std::pair<const GeomDet*, TrajectoryStateOnSurface> DetWithState;
0020 typedef BoundSurface::PositionType PositionType;
0021 typedef BoundSurface::RotationType RotationType;
0022 typedef TrajectoryStateOnSurface TrajectoryState;
0023
0024 GeometricSearchDet(bool doHaveGroups) : haveGroups(doHaveGroups) {}
0025 virtual ~GeometricSearchDet();
0026
0027
0028 virtual const BoundSurface& surface() const = 0;
0029
0030
0031 virtual const Surface::PositionType& position() const { return surface().position(); }
0032
0033
0034
0035
0036
0037 virtual const std::vector<const GeometricSearchDet*>& components() const = 0;
0038
0039
0040
0041
0042 virtual const std::vector<const GeomDet*>& basicComponents() const = 0;
0043
0044
0045
0046
0047
0048
0049
0050
0051
0052 virtual std::pair<bool, TrajectoryStateOnSurface> compatible(const TrajectoryStateOnSurface& ts,
0053 const Propagator&,
0054 const MeasurementEstimator&) const = 0;
0055
0056
0057
0058
0059
0060
0061
0062
0063 virtual std::vector<DetWithState> compatibleDets(const TrajectoryStateOnSurface& startingState,
0064 const Propagator& prop,
0065 const MeasurementEstimator& est) const;
0066 virtual void compatibleDetsV(const TrajectoryStateOnSurface& startingState,
0067 const Propagator& prop,
0068 const MeasurementEstimator& est,
0069 std::vector<DetWithState>& result) const;
0070
0071
0072
0073
0074
0075
0076
0077
0078
0079
0080
0081
0082
0083
0084
0085
0086
0087
0088
0089
0090 virtual std::vector<DetGroup> groupedCompatibleDets(const TrajectoryStateOnSurface& startingState,
0091 const Propagator& prop,
0092 const MeasurementEstimator& est) const;
0093
0094 virtual void groupedCompatibleDetsV(const TrajectoryStateOnSurface& startingState,
0095 const Propagator& prop,
0096 const MeasurementEstimator& est,
0097 std::vector<DetGroup>& result) const;
0098
0099 bool hasGroups() const { return haveGroups; }
0100
0101 protected:
0102 GeomDetCompatibilityChecker theCompatibilityChecker;
0103 bool haveGroups;
0104 };
0105
0106 #endif