Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-10-25 10:05:45

0001 #ifndef TrajectoryFilter_H
0002 #define TrajectoryFilter_H
0003 
0004 #include <string>
0005 
0006 namespace edm {
0007   class Event;
0008   class EventSetup;
0009   class ConsumesCollector;
0010 }  // namespace edm
0011 
0012 class Trajectory;
0013 class TempTrajectory;
0014 
0015 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0016 #include "TrackingTools/PatternTools/interface/Trajectory.h"
0017 #include "TrackingTools/PatternTools/interface/TempTrajectory.h"
0018 //#include "RecoTracker/CkfPattern/interface/TempTrajectory.h"
0019 
0020 /** An abstract base class for Filter<TempTrajectory>.
0021  *  Adds a name() method.
0022  *  This class is useful because the CkfTrajectoryBuilder
0023  *  uses TrajectoryFilters as stopping conditions.
0024  */
0025 
0026 #include "RecoTracker/Record/interface/CkfComponentsRecord.h"
0027 
0028 class TrajectoryFilter {
0029 public:
0030   //a type def while deciding what the record it
0031   typedef CkfComponentsRecord Record;
0032 
0033   static const bool qualityFilterIfNotContributing = true;
0034   static const bool toBeContinuedIfNotContributing = true;
0035 
0036   virtual ~TrajectoryFilter();
0037   virtual std::string name() const = 0;
0038 
0039   virtual void setEvent(const edm::Event& iEvent, const edm::EventSetup& iSetup);
0040 
0041   virtual bool operator()(TempTrajectory& t) const { return toBeContinued(t); }
0042   virtual bool operator()(Trajectory& t) const { return toBeContinued(t); }
0043 
0044   virtual bool qualityFilter(const TempTrajectory&) const = 0;
0045   virtual bool qualityFilter(const Trajectory&) const = 0;
0046 
0047   virtual bool toBeContinued(TempTrajectory&) const = 0;
0048   virtual bool toBeContinued(Trajectory&) const = 0;
0049 };
0050 
0051 #endif