CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_2_9/src/DQMOffline/Trigger/src/EgHLTOffEle.cc

Go to the documentation of this file.
00001 #include "DQMOffline/Trigger/interface/EgHLTOffEle.h"
00002 
00003 using namespace egHLT;
00004 
00005 float OffEle::sigmaEtaEta()const
00006 {
00007   if(fabs(etaSC())<1.479) return clusShapeData_.sigmaEtaEta; //barrel case, no correction
00008   else{ //endcap, need to apply eta correction
00009     return clusShapeData_.sigmaEtaEta - 0.02*( fabs(etaSC()) - 2.3);
00010   } 
00011 
00012 }
00013 
00014 //defining the == operator
00015 //bool operator==(const std::pair<TrigCodes::TrigBitSet,int>& lhs,const TrigCodes::TrigBitSet& rhs){return lhs.first==rhs;}
00016 //bool operator==(const TrigCodes::TrigBitSet& lhs,const std::pair<TrigCodes::TrigBitSet,int>& rhs){return lhs==rhs.first;}
00017 
00018 int OffEle::trigCutsCutCode(const TrigCodes::TrigBitSet& trigger)const
00019 {
00020   //yes maybe a sorted vector might be better but 1) its small and 2) bitset doesnt support < operator
00021   //okay laugh, for some reason I cant overload the == operator (brain just not working), hence the non stl'y way
00022   //std::vector<std::pair<TrigCodes::TrigBitSet,int> >::const_iterator it;
00023   //it = std::find(trigCutsCodes_.begin(),trigCutsCodes_.end(),trigger);
00024   //if(it!=trigCutsCodes_.end()) return it->second;
00025   //else return 0; //defaults to passing
00026 
00027   for(size_t i=0;i<trigCutsCutCodes_.size();i++) if(trigger==trigCutsCutCodes_[i].first) return trigCutsCutCodes_[i].second;
00028   return 0; //defaults to passing
00029 }
00030 
00031 
00032 // float EgHLTOffEle::sigmaIEtaIEta()const
00033 // {
00034 //   if(fabs(etaSC())<1.479) return clusShapeData_.sigmaIEtaIEta; //barrel case, no correction
00035 //   else{ //endcap, need to apply eta correction
00036 //     return clusShapeData_.sigmaIEtaIEta - 0.02*( fabs(etaSC()) - 2.3);
00037 //   } 
00038 
00039 // }