Go to the documentation of this file.00001 #ifndef MuonIsolation_CandViewExtractor_H
00002 #define MuonIsolation_CandViewExtractor_H
00003
00004 #include <string>
00005 #include <vector>
00006
00007
00008 #include "DataFormats/RecoCandidate/interface/IsoDeposit.h"
00009 #include "DataFormats/TrackReco/interface/Track.h"
00010 #include "DataFormats/TrackReco/interface/TrackFwd.h"
00011 #include "DataFormats/Candidate/interface/Candidate.h"
00012 #include "DataFormats/Candidate/interface/CandidateFwd.h"
00013 #include "PhysicsTools/IsolationAlgos/interface/IsoDepositExtractor.h"
00014
00015 namespace muonisolation {
00016
00017 class CandViewExtractor : public reco::isodeposit::IsoDepositExtractor {
00018
00019 public:
00020
00021 CandViewExtractor(){};
00022 CandViewExtractor(const edm::ParameterSet& par);
00023
00024 virtual ~CandViewExtractor(){}
00025
00026 virtual void fillVetos (const edm::Event & ev,
00027 const edm::EventSetup & evSetup, const reco::TrackCollection & cand) { }
00028
00029
00030
00031
00032
00033
00034
00035
00036 virtual reco::IsoDeposit deposit (const edm::Event & ev,
00037 const edm::EventSetup & evSetup, const reco::Track & muon) const {
00038 return depositFromObject(ev, evSetup, muon);
00039 }
00040
00041 virtual reco::IsoDeposit deposit (const edm::Event & ev,
00042 const edm::EventSetup & evSetup, const reco::Candidate & muon) const {
00043 return depositFromObject(ev, evSetup, muon);
00044 }
00045
00046 private:
00047 reco::IsoDeposit::Veto veto( const reco::IsoDeposit::Direction & dir) const;
00048
00049 template<typename T>
00050 reco::IsoDeposit depositFromObject( const edm::Event & ev,
00051 const edm::EventSetup & evSetup, const T &cand) const ;
00052
00053
00054 edm::InputTag theCandViewTag;
00055 std::string theDepositLabel;
00056 double theDiff_r;
00057 double theDiff_z;
00058 double theDR_Max;
00059 double theDR_Veto;
00060 };
00061
00062 }
00063
00064 #endif