CMS 3D CMS Logo

EBEECutValues.h
Go to the documentation of this file.
1 #ifndef EgammaAnalysis_ElectronTools_EBEECutValues_h
2 #define EgammaAnalysis_ElectronTools_EBEECutValues_h
3 
6 
7 template<typename T>
9 private:
12  const double barrelCutOff_=1.479; //this is currrently used to identify if object is barrel or endcap but may change
13 
14 public:
16  barrel_(params.getParameter<T>(name+"EB")),
17  endcap_(params.getParameter<T>(name+"EE")){}
18  template<typename CandType>
19  T operator()(const edm::Ptr<CandType>& cand)const{return isBarrel(cand) ? barrel_ : endcap_;}
20 
21 private:
22  template<typename CandType>
23  const bool isBarrel(const edm::Ptr<CandType>& cand)const{return std::abs(cand->superCluster()->position().eta())<barrelCutOff_;}
24 
25 };
26 
29 
30 
31 
32 #endif
EBEECutValuesT< double > EBEECutValues
Definition: EBEECutValues.h:27
T operator()(const edm::Ptr< CandType > &cand) const
Definition: EBEECutValues.h:19
EBEECutValuesT(const edm::ParameterSet &params, const std::string &name)
Definition: EBEECutValues.h:15
const double barrelCutOff_
Definition: EBEECutValues.h:12
EBEECutValuesT< int > EBEECutValuesInt
Definition: EBEECutValues.h:28
const bool isBarrel(const edm::Ptr< CandType > &cand) const
Definition: EBEECutValues.h:23
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
long double T