// HTrackGenerator.h #ifndef HTrackGenerator_H #define HTrackGenerator_H // Generates an HTrack from a VTrack using its track error matrix // and a list of hit generators. The VTrack is propagated to each // of the hit generator surfaces and used to generate a cluster which // is in turn used to generate a hit. This is repeated until a hit is // succesfully produced at each surface. The first hit from each // surface is assigned to the HTrack. #include #include "ptr/Ptr.h" #include "ptr/SharedDeletePolicy.h" #include "trfbase/SurfacePtr.h" #include "trfbase/PropagatorPtr.h" #include "trfutil/RandomGenerator.h" #include "trfbase/TrackVector.h" #include "trfbase/HitGenerator.h" namespace trf { class Surface; class Propagator; class VTrack; class HTrack; class HTrackGenerator : public RandomGenerator { public: // typedef for the list of hit generators typedef Ptr HitGeneratorPtr; typedef std::list HitGeneratorList; private: // The Hit generators. HitGeneratorList _hgens; // The starting surface. SurfacePtr _psrf; // The track error matrix. TrackError _terr; // Propagator. PropagatorPtr _pprop; public: // Constructor. HTrackGenerator(const HitGeneratorList& hgens, const Propagator& prop, const Surface& srf, const TrackError& terr); // Destructor. virtual ~HTrackGenerator(); // Return a new HTrack. // Return 0 for failure. HTrack* new_track(const VTrack& trv); }; } // end namespace trf #endif