CMS 3D CMS Logo

TriggerBitChecker.h
Go to the documentation of this file.
1 #ifndef PhysicsTools_Heppy_TriggerBitChecker_h
2 #define PhysicsTools_Heppy_TriggerBitChecker_h
3 
7 #include <vector>
8 #include <string>
9 
10 namespace heppy {
11 
13  public:
14  struct pathStruct {
15  pathStruct(const std::string &s) : pathName(s), first(0), last(99999999) {}
16  pathStruct() : pathName(), first(0), last(99999999) {}
18  unsigned int first;
19  unsigned int last;
20  };
21 
22  TriggerBitChecker(const std::string &path = "DUMMY");
23  TriggerBitChecker(const std::vector<std::string> &paths);
25 
26  bool check(const edm::EventBase &event, const edm::TriggerResults &result) const;
28  const edm::TriggerResults &result_tr,
29  const pat::PackedTriggerPrescales &result) const;
30  int getprescale(const edm::EventBase &event,
31  const edm::TriggerResults &result_tr,
32  const pat::PackedTriggerPrescales &result) const;
33 
34  private:
35  // list of path name prefixes
36  std::vector<pathStruct> paths_;
37 
39  mutable std::vector<unsigned int> indices_;
40 
42  void syncIndices(const edm::EventBase &event, const edm::TriggerResults &result) const;
44 
46  void rmstar();
47  };
48 } // namespace heppy
49 
50 #endif
TriggerResults.h
heppy::TriggerBitChecker::getprescale
int getprescale(const edm::EventBase &event, const edm::TriggerResults &result_tr, const pat::PackedTriggerPrescales &result) const
Definition: TriggerBitChecker.cc:56
heppy::TriggerBitChecker::pathStruct
Definition: TriggerBitChecker.h:14
heppy::TriggerBitChecker::rmstar
void rmstar()
executes a 'rm -rf *' in current directory
Definition: TriggerBitChecker.cc:88
heppy::TriggerBitChecker::~TriggerBitChecker
~TriggerBitChecker()
Definition: TriggerBitChecker.h:24
EventBase.h
heppy::TriggerBitChecker::returnPathStruct
pathStruct returnPathStruct(const std::string &path) const
Definition: TriggerBitChecker.cc:17
alignCSCRings.s
s
Definition: alignCSCRings.py:92
heppy::TriggerBitChecker::indices_
std::vector< unsigned int > indices_
Definition: TriggerBitChecker.h:39
PackedTriggerPrescales.h
edm::Hash< ParameterSetType >
heppy::TriggerBitChecker::paths_
std::vector< pathStruct > paths_
Definition: TriggerBitChecker.h:36
heppy::TriggerBitChecker::syncIndices
void syncIndices(const edm::EventBase &event, const edm::TriggerResults &result) const
sync indices with path names
Definition: TriggerBitChecker.cc:75
heppy
TAKEN FROM http://cmssw.cvs.cern.ch/cgi-bin/cmssw.cgi/CMSSW/ElectroWeakAnalysis/Utilities/src/PdfWeig...
Definition: AlphaT.h:16
heppy::TriggerBitChecker::check
bool check(const edm::EventBase &event, const edm::TriggerResults &result) const
Definition: TriggerBitChecker.cc:27
heppy::TriggerBitChecker::pathStruct::first
unsigned int first
Definition: TriggerBitChecker.h:18
heppy::TriggerBitChecker::pathStruct::pathStruct
pathStruct()
Definition: TriggerBitChecker.h:16
heppy::TriggerBitChecker::pathStruct::last
unsigned int last
Definition: TriggerBitChecker.h:19
pat::PackedTriggerPrescales
Definition: PackedTriggerPrescales.h:10
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
heppy::TriggerBitChecker::lastID_
edm::ParameterSetID lastID_
Definition: TriggerBitChecker.h:38
heppy::TriggerBitChecker
Definition: TriggerBitChecker.h:12
heppy::TriggerBitChecker::pathStruct::pathName
std::string pathName
Definition: TriggerBitChecker.h:17
heppy::TriggerBitChecker::check_unprescaled
bool check_unprescaled(const edm::EventBase &event, const edm::TriggerResults &result_tr, const pat::PackedTriggerPrescales &result) const
Definition: TriggerBitChecker.cc:39
edm::EventBase
Definition: EventBase.h:46
heppy::TriggerBitChecker::pathStruct::pathStruct
pathStruct(const std::string &s)
Definition: TriggerBitChecker.h:15
Skims_PA_cff.paths
paths
Definition: Skims_PA_cff.py:18
mps_fire.result
result
Definition: mps_fire.py:311
castor_dqm_sourceclient_file_cfg.path
path
Definition: castor_dqm_sourceclient_file_cfg.py:37
event
Definition: event.py:1
edm::TriggerResults
Definition: TriggerResults.h:35
heppy::TriggerBitChecker::TriggerBitChecker
TriggerBitChecker(const std::string &path="DUMMY")
Definition: TriggerBitChecker.cc:9