CMS 3D CMS Logo

GsfEleFull5x5SigmaIEtaIEtaWithSatCut.cc
Go to the documentation of this file.
5 
7 public:
9 
10  result_type operator()(const reco::GsfElectronPtr&) const override final;
11 
12  void setConsumes(edm::ConsumesCollector&) override final;
13  void getEventContent(const edm::EventBase&) override final;
14 
15  double value(const reco::CandidatePtr& cand) const override final;
16 
17  CandidateType candidateType() const override final {
18  return ELECTRON;
19  }
20 
21 private:
25 
26 };
27 
30  "GsfEleFull5x5SigmaIEtaIEtaWithSatCut");
31 
34  maxSigmaIEtaIEtaCut_(params,"maxSigmaIEtaIEta"),
35 
36  maxNrSatCrysIn5x5Cut_(params,"maxNrSatCrysIn5x5"){
37  contentTags_.emplace("nrSatCrysValueMap",params.getParameter<edm::InputTag>("nrSatCrysValueMap"));
38 }
39 
41  contentTokens_.emplace("nrSatCrysValueMap",cc.consumes<edm::ValueMap<int> >(contentTags_["nrSatCrysValueMap"]));
42 }
43 
45  ev.getByLabel(contentTags_["nrSatCrysValueMap"],nrSatCrysValueMap_);
46 
47 }
48 
49 
50 CutApplicatorBase::result_type
53 
54  if((*nrSatCrysValueMap_)[cand]>maxNrSatCrysIn5x5Cut_(cand)) return true;
55  else return cand->full5x5_sigmaIetaIeta() < maxSigmaIEtaIEtaCut_(cand);
56 
57 }
58 
60 value(const reco::CandidatePtr& cand) const {
61  reco::GsfElectronPtr ele(cand);
62  return ele->full5x5_sigmaIetaIeta();
63 }
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
T getParameter(std::string const &) const
void getEventContent(const edm::EventBase &) override final
std::unordered_map< std::string, edm::EDGetToken > contentTokens_
CandidateType candidateType() const override final
bool ev
result_type operator()(const reco::GsfElectronPtr &) const override final
std::unordered_map< std::string, edm::InputTag > contentTags_
float full5x5_sigmaIetaIeta() const
Definition: GsfElectron.h:455
bool getByLabel(InputTag const &, Handle< T > &) const
Definition: EventBase.h:94
#define DEFINE_EDM_PLUGIN(factory, type, name)
double value(const reco::CandidatePtr &cand) const override final
edm::Handle< edm::ValueMap< int > > nrSatCrysValueMap_
void setConsumes(edm::ConsumesCollector &) override final