CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_6_1_1/src/DQMOffline/Trigger/src/EgHLTOffPho.cc

Go to the documentation of this file.
00001 #include "DQMOffline/Trigger/interface/EgHLTOffPho.h"
00002 
00003 using namespace egHLT;
00004 
00005 float OffPho::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 int OffPho::trigCutsCutCode(const TrigCodes::TrigBitSet& trigger)const
00015 {
00016   //yes maybe a sorted vector might be better but 1) its small and 2) bitset doesnt support < operator
00017   //okay laugh, for some reason I cant overload the == operator (brain just not working), hence the non stl'y way
00018   //std::vector<std::pair<TrigCodes::TrigBitSet,int> >::const_iterator it;
00019   //it = std::find(trigCutsCodes_.begin(),trigCutsCodes_.end(),trigger);
00020   //if(it!=trigCutsCodes_.end()) return it->second;
00021   //else return 0; //defaults to passing
00022 
00023   for(size_t i=0;i<trigCutsCutCodes_.size();i++) if(trigger==trigCutsCutCodes_[i].first) return trigCutsCutCodes_[i].second;
00024   return 0; //defaults to passing
00025 }