CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_1/src/RecoTracker/TkDetLayers/src/PixelBarrelLayer.h

Go to the documentation of this file.
00001 #ifndef TkDetLayers_PixelBarrelLayer_h
00002 #define TkDetLayers_PixelBarrelLayer_h
00003 
00004 
00005 #include "TrackingTools/DetLayers/interface/RodBarrelLayer.h"
00006 #include "PixelRod.h"
00007 #include "Utilities/BinningTools/interface/PeriodicBinFinderInPhi.h"
00008 #include "SubLayerCrossings.h"
00009 
00010 
00011 
00016 #pragma GCC visibility push(hidden)
00017 class PixelBarrelLayer GCC11_FINAL : public RodBarrelLayer, public GeometricSearchDetWithGroups {
00018  public:
00019   typedef PeriodicBinFinderInPhi<double>   BinFinderType;
00020 
00021 
00022   PixelBarrelLayer(std::vector<const PixelRod*>& innerRods,
00023                    std::vector<const PixelRod*>& outerRods);
00024   
00025   ~PixelBarrelLayer();
00026   
00027   // GeometricSearchDet interface
00028   
00029   virtual const std::vector<const GeomDet*>& basicComponents() const {return theBasicComps;}
00030   
00031   virtual const std::vector<const GeometricSearchDet*>& components() const {return theComps;}
00032 
00033   void groupedCompatibleDetsV( const TrajectoryStateOnSurface& tsos,
00034                                const Propagator& prop,
00035                                const MeasurementEstimator& est,
00036                                std::vector<DetGroup> & result) const;
00037     
00038 
00039   // DetLayer interface
00040   virtual SubDetector subDetector() const { return GeomDetEnumerators::PixelBarrel;}
00041 
00042 
00043  private:
00044   // private methods for the implementation of groupedCompatibleDets()
00045   // the implementation of the methods is the same of the TOBLayer one.
00046   // In the future, to move common code in a common place!
00047 
00048   SubLayerCrossings computeCrossings( const TrajectoryStateOnSurface& tsos,
00049                                       PropagationDirection propDir) const;
00050   
00051   bool addClosest( const TrajectoryStateOnSurface& tsos,
00052                    const Propagator& prop,
00053                    const MeasurementEstimator& est,
00054                    const SubLayerCrossing& crossing,
00055                    std::vector<DetGroup>& result) const;
00056 
00057   float computeWindowSize( const GeomDet* det, 
00058                            const TrajectoryStateOnSurface& tsos, 
00059                            const MeasurementEstimator& est) const;
00060   
00061   double calculatePhiWindow( double Xmax, const GeomDet& det,
00062                              const TrajectoryStateOnSurface& state) const;
00063 
00064   bool overlap( const GlobalPoint& gpos, const GeometricSearchDet& rod, float phiWin) const;
00065 
00066 
00067   void searchNeighbors( const TrajectoryStateOnSurface& tsos,
00068                         const Propagator& prop,
00069                         const MeasurementEstimator& est,
00070                         const SubLayerCrossing& crossing,
00071                         float window, 
00072                         std::vector<DetGroup>& result,
00073                         bool checkClosest) const;
00074 
00075   const std::vector<const GeometricSearchDet*>& subLayer( int ind) const {
00076     return (ind==0 ? theInnerComps : theOuterComps);}
00077   
00078   BoundCylinder* cylinder( const std::vector<const GeometricSearchDet*>& rods) const ;
00079 
00080 
00081  private:
00082   std::vector<const GeometricSearchDet*> theComps;
00083   std::vector<const GeometricSearchDet*> theInnerComps;
00084   std::vector<const GeometricSearchDet*> theOuterComps;
00085   std::vector<const GeomDet*> theBasicComps;
00086 
00087   BinFinderType    theInnerBinFinder;
00088   BinFinderType    theOuterBinFinder;
00089 
00090   ReferenceCountingPointer<BoundCylinder>  theInnerCylinder;
00091   ReferenceCountingPointer<BoundCylinder>  theOuterCylinder;
00092 
00093   
00094 };
00095 
00096 
00097 #pragma GCC visibility pop
00098 #endif