CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_2_9/src/RecoEgamma/EgammaTools/interface/ConversionInfo.h

Go to the documentation of this file.
00001 #ifndef EgammaTools_ConversionInfo_h
00002 #define EgammaTools_ConversionInfo_h
00003 
00004 #include "FWCore/MessageLogger/interface/MessageLogger.h"
00005 #include "DataFormats/TrackReco/interface/TrackFwd.h"
00006 //#include "DataFormats/TrackReco/interface/Track.h"
00007 //#include "DataFormats/GsfTrackReco/interface/GsfTrack.h"
00008 #include "DataFormats/GsfTrackReco/interface/GsfTrackFwd.h"
00009 #include "DataFormats/Math/interface/Point3D.h"
00010 
00011 
00012 class ConversionInfo
00013  {
00014   public:
00015 
00016     ConversionInfo()
00017      {
00018       dist_ = -9999.;
00019       dcot_ = -9999.;
00020       radiusOfConversion_ = -9999.;
00021       pointOfConversion_ = math::XYZPoint(-9999.,-9999.,-9999);
00022       conversionPartnerCtfTk_ = reco::TrackRef();
00023       conversionPartnerGsfTk_ = reco::GsfTrackRef();
00024       deltaMissingHits_ = -9999;
00025       flag_ = -9999;
00026      }
00027     ~ConversionInfo() {}
00028     ConversionInfo
00029      ( double dist, double dcot,
00030        double radiusOfConversion, math::XYZPoint pointOfConversion,
00031        reco::TrackRef conversionPartnerCtfTk,
00032        reco::GsfTrackRef conversionPartnerGsfTk,
00033        int deltaMissingHits,
00034        int flag )
00035      {
00036       dist_ = dist;
00037       dcot_ = dcot;
00038       radiusOfConversion_ = radiusOfConversion;
00039       pointOfConversion_ = pointOfConversion;
00040       conversionPartnerCtfTk_ = conversionPartnerCtfTk;
00041       conversionPartnerGsfTk_ = conversionPartnerGsfTk;
00042       deltaMissingHits_ = deltaMissingHits;
00043       flag_ = flag;
00044      }
00045     double dist() const {return dist_ ; }
00046     double dcot() const {return dcot_ ; }
00047     double radiusOfConversion() const { return radiusOfConversion_ ; }
00048     math::XYZPoint pointOfConversion() const { return pointOfConversion_ ; }
00049     reco::TrackRef conversionPartnerCtfTk() const { return conversionPartnerCtfTk_ ; }
00050 
00051     //if the partner track is found in the  GSF track collection,
00052     //we return a ref to the GSF partner track
00053     reco::GsfTrackRef conversionPartnerGsfTk() const { return conversionPartnerGsfTk_ ; }
00054 
00055     //if the partner track is found in the  CTF track collection,
00056     //we return a ref to the CTF partner track
00057     int deltaMissingHits() const { return deltaMissingHits_ ; }
00058     /*
00059       if(flag == 0) //Partner track found in the CTF collection using the electron's CTF track
00060       if(flag == 1) //Partner track found in the CTF collection using the electron's GSF track
00061       if(flag == 2) //Partner track found in the GSF collection using the electron's CTF track
00062       if(flag == 3) //Partner track found in the GSF collection using the electron's GSF track
00063      */
00064     int flag() const { return flag_ ; }
00065 
00066     reco::TrackRef conversionPartnerTk() const {
00067       edm::LogWarning("ConversionInfo") << "The conversionPartnerTk() function is deprecated, but still returns the CTF partner track if found! \n"
00068                 << "Please use either conversionPartnerCtfTk() and conversionPartnerGsfTk() instead. \n";
00069       return conversionPartnerCtfTk_;
00070     }
00071 
00072   private:
00073 
00074     double dist_;
00075     double dcot_;
00076     double radiusOfConversion_;
00077     math::XYZPoint pointOfConversion_;
00078     reco::TrackRef conversionPartnerCtfTk_;
00079     reco::GsfTrackRef conversionPartnerGsfTk_;
00080     int deltaMissingHits_;
00081     int flag_;
00082 
00083  } ;
00084 
00085 
00086 #endif