1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
#ifndef BCToEFilterAlgo_h
#define BCToEFilterAlgo_h
/** \class BCToEFilterAlgo
*
* BCToEFilterAlgo
* returns true for events that have an electron, above configurable eT threshold and within |eta|<2.5, that has an ancestor of a b or c quark
*
* \author J Lamb, UCSB
*
************************************************************/
// user include files
#include "FWCore/Framework/interface/Frameworkfwd.h"
#include "FWCore/Utilities/interface/EDGetToken.h"
#include "DataFormats/HepMCCandidate/interface/GenParticleFwd.h"
class BCToEFilterAlgo {
public:
BCToEFilterAlgo(const edm::ParameterSet&, edm::ConsumesCollector&& iC);
~BCToEFilterAlgo();
bool filter(const edm::Event& iEvent) const;
bool hasBCAncestors(const reco::GenParticle& gp) const;
private:
bool isBCHadron(const reco::GenParticle& gp) const;
bool isBCMeson(const reco::GenParticle& gp) const;
bool isBCBaryon(const reco::GenParticle& gp) const;
//filter parameters:
const float maxAbsEta_;
const float eTThreshold_;
const edm::EDGetTokenT<reco::GenParticleCollection> genParSource_;
};
#endif
|