CMS 3D CMS Logo

Phase2TrackerRecHit1D.h
Go to the documentation of this file.
1 #ifndef DATAFORMATS_TRACKERRECHIT2D_PHASE2TRACKERRECHIT1D_H
2 #define DATAFORMATS_TRACKERRECHIT2D_PHASE2TRACKERRECHIT1D_H
3 
5 
7 
8 #include "TkCloner.h"
9 
11 public:
14 
16 
17  ~Phase2TrackerRecHit1D() override {}
18 
19  Phase2TrackerRecHit1D(const LocalPoint& pos, const LocalError& err, GeomDet const& idet, CluRef const& clus)
20  : TrackerSingleRecHit(pos, err, idet, clus) {}
21 
22  Phase2TrackerRecHit1D* clone() const override { return new Phase2TrackerRecHit1D(*this); }
23  RecHitPointer cloneSH() const override { return std::make_shared<Phase2TrackerRecHit1D>(*this); }
24 
25  CluRef cluster() const { return cluster_phase2OT(); }
26  void setClusterRef(CluRef const& ref) { setClusterPhase2Ref(ref); }
27 
28  bool isPhase2() const override { return true; }
29  //FIXME::check dimension of this!!
30  int dimension() const override { return 2; }
31  void getKfComponents(KfComponentsHolder& holder) const override { getKfComponents2D(holder); }
32 
33  bool canImproveWithTrack() const override { return true; }
34 
35 private:
36  // double dispatch
37  Phase2TrackerRecHit1D* clone_(TkCloner const& cloner, TrajectoryStateOnSurface const& tsos) const override {
38  return cloner(*this, tsos).release();
39  }
40  RecHitPointer cloneSH_(TkCloner const& cloner, TrajectoryStateOnSurface const& tsos) const override {
41  return cloner.makeShared(*this, tsos);
42  }
43 };
44 
46 
47 #endif
Phase2TrackerRecHit1D(const LocalPoint &pos, const LocalError &err, GeomDet const &idet, CluRef const &clus)
Phase2TrackerRecHit1D * clone() const override
RecHitPointer cloneSH() const override
OmniClusterRef::Phase2Cluster1DRef ClusterRef
int dimension() const override
ClusterPhase2Ref cluster_phase2OT() const
edmNew::DetSetVector< Phase2TrackerRecHit1D > Phase2TrackerRecHit1DCollectionNew
bool isPhase2() const override
void setClusterRef(CluRef const &ref)
TrackingRecHit::ConstRecHitPointer makeShared(TrackingRecHit::ConstRecHitPointer const &hit, TrajectoryStateOnSurface const &tsos) const
Definition: TkCloner.h:24
std::shared_ptr< TrackingRecHit const > RecHitPointer
bool canImproveWithTrack() const override
void getKfComponents(KfComponentsHolder &holder) const override
void setClusterPhase2Ref(ClusterPhase2Ref const &ref)
OmniClusterRef::Phase2Cluster1DRef CluRef
void getKfComponents2D(KfComponentsHolder &holder) const
RecHitPointer cloneSH_(TkCloner const &cloner, TrajectoryStateOnSurface const &tsos) const override
Phase2TrackerRecHit1D * clone_(TkCloner const &cloner, TrajectoryStateOnSurface const &tsos) const override