CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_6_1_1/src/RecoTracker/TransientTrackingRecHit/interface/ProjectedRecHit2D.h

Go to the documentation of this file.
00001 #ifndef RECOTRACKER_TRANSIENTRACKINGRECHIT_ProjectedRecHit2D_H
00002 #define RECOTRACKER_TRANSIENTRACKINGRECHIT_ProjectedRecHit2D_H
00003 
00004 #include "DataFormats/TrackerRecHit2D/interface/ProjectedSiStripRecHit2D.h"
00005 #include "TrackingTools/TransientTrackingRecHit/interface/GenericTransientTrackingRecHit.h"
00006 #include "TrackingTools/TransientTrackingRecHit/interface/HelpertRecHit2DLocalPos.h"
00007 #include "RecoLocalTracker/ClusterParameterEstimator/interface/StripClusterParameterEstimator.h"
00008 
00009 class SiStripRecHit2D;
00010 
00011 class ProjectedRecHit2D GCC11_FINAL : public GenericTransientTrackingRecHit {
00012 public:
00013 
00014   virtual void getKfComponents( KfComponentsHolder & holder ) const {
00015       HelpertRecHit2DLocalPos().getKfComponents(holder, *hit(), *det()); 
00016   }
00017 
00018 
00019   virtual AlgebraicSymMatrix parametersError() const {
00020     return HelpertRecHit2DLocalPos().parError( localPositionError(), *det()); 
00021   }
00022 
00023   const GeomDetUnit* detUnit() const {return 0;}
00024   const GeomDet* originalDet() const {return theOriginalDet;}
00025 
00026   static RecHitPointer build( const GeomDet * geom,
00027                               const GeomDet* originaldet,
00028                               const ProjectedSiStripRecHit2D* rh,
00029                               const StripClusterParameterEstimator* cpe,
00030                               bool computeCoarseLocalPosition=false) {
00031     return RecHitPointer( new ProjectedRecHit2D( geom, originaldet, rh, cpe, computeCoarseLocalPosition));
00032   }
00033 
00034   static RecHitPointer build( const LocalPoint& pos, const LocalError& err, 
00035                               const GeomDet* det, const GeomDet* originaldet,
00036                               const TransientTrackingRecHit& originalHit ) {
00037     return RecHitPointer( new ProjectedRecHit2D( pos, err, det, originaldet, originalHit));
00038   }
00039 
00040   RecHitPointer clone( const TrajectoryStateOnSurface& ts) const;
00041 
00042   const SiStripRecHit2D& originalHit() const { return static_cast<const ProjectedSiStripRecHit2D*>( hit() )->originalHit();}
00043 
00044   virtual ConstRecHitContainer  transientHits () const;
00045 
00046 private:
00047   const StripClusterParameterEstimator* theCPE;
00048   const GeomDet* theOriginalDet;
00049 
00050   ProjectedRecHit2D( const LocalPoint& pos, const LocalError& err,
00051                      const GeomDet* det, const GeomDet* originaldet, 
00052                      const TransientTrackingRecHit& originalHit);
00053 
00054   ProjectedRecHit2D( const GeomDet * geom, const GeomDet* originaldet,
00055                      const ProjectedSiStripRecHit2D* rh,
00056                      const StripClusterParameterEstimator* cpe,
00057                      bool computeCoarseLocalPosition);
00058 
00059   virtual ProjectedRecHit2D* clone() const {
00060     return new ProjectedRecHit2D(*this);
00061   }
00062 
00063 };
00064 
00065 
00066 
00067 #endif