CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_1/src/DataFormats/JetReco/interface/TrackExtrapolation.h

Go to the documentation of this file.
00001 #ifndef DataFormats_TrackReco_interface_TrackExtrapolation_h
00002 #define DataFormats_TrackReco_interface_TrackExtrapolation_h
00003 /* \class reco::TrackExtrapolation TrackExtrapolation.h DataFormats/TrackReco/interface/TrackExtrapolation.h
00004 *
00005 * This class represents the track state at several radii (specified by user in producer).
00006 * It stores a TrackRef to the original track, as well as vectors of the positions and  momenta
00007 * of the track at the various radii. 
00008 *
00009 * \author Salvatore Rappoccio, JHU
00010 *
00011 *
00012 */
00013 
00014 #include "DataFormats/TrackReco/interface/Track.h"
00015 #include "DataFormats/TrackReco/interface/TrackFwd.h"
00016 #include "DataFormats/Math/interface/Vector3D.h"
00017 #include "DataFormats/Math/interface/Point3D.h"
00018 
00019 #include <vector>
00020 
00021 namespace reco {
00022   class TrackExtrapolation {
00023     typedef ROOT::Math::PositionVector3D<ROOT::Math::Cartesian3D<Double32_t> > Point;
00024     typedef ROOT::Math::DisplacementVector3D<ROOT::Math::Cartesian3D<Double32_t> > Vector;
00025   public:
00026 
00027 
00028     TrackExtrapolation() {}
00029     TrackExtrapolation( reco::TrackRef const & track,
00030                         std::vector<Point> const & pos,
00031                         std::vector<Vector> const & mom) :
00032     track_(track)
00033     {
00034       pos_.resize( pos.size() );
00035       copy( pos.begin(), pos.end(), pos_.begin() );
00036       mom_.resize( mom.size() );
00037       copy( mom.begin(), mom.end(), mom_.begin() );
00038     }
00039 
00040     ~TrackExtrapolation() {}
00041 
00042     reco::TrackRef const &                 track()      const { return track_;}
00043     std::vector<Point> const &  positions()  const { return pos_;}
00044     std::vector<Vector> const & momenta()    const { return mom_;}
00045 
00046   protected:
00047     reco::TrackRef    track_;
00048     std::vector<Point>      pos_;
00049     std::vector<Vector>     mom_;
00050   };
00051 }
00052 
00053 
00054 #endif