File indexing completed on 2024-04-06 12:22:17
0001 #ifndef L1GtConfigProducers_L1GtPrescaleFactorsAndMasksTester_h
0002 #define L1GtConfigProducers_L1GtPrescaleFactorsAndMasksTester_h
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022 #include "FWCore/Framework/interface/one/EDAnalyzer.h"
0023
0024 #include "FWCore/Framework/interface/Event.h"
0025 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0026
0027
0028 class L1GtPrescaleFactors;
0029 class L1GtTriggerMask;
0030
0031 class L1GtPrescaleFactorsAlgoTrigRcd;
0032 class L1GtPrescaleFactorsTechTrigRcd;
0033 class L1GtTriggerMaskAlgoTrigRcd;
0034 class L1GtTriggerMaskTechTrigRcd;
0035 class L1GtTriggerMaskVetoAlgoTrigRcd;
0036 class L1GtTriggerMaskVetoTechTrigRcd;
0037
0038
0039 class L1GtPrescaleFactorsAndMasksTester
0040 : public edm::one::EDAnalyzer<edm::one::WatchRuns, edm::one::WatchLuminosityBlocks> {
0041 public:
0042
0043 explicit L1GtPrescaleFactorsAndMasksTester(const edm::ParameterSet&);
0044
0045 struct Tokens {
0046 edm::ESGetToken<L1GtPrescaleFactors, L1GtPrescaleFactorsAlgoTrigRcd> m_l1GtPfAlgo;
0047 edm::ESGetToken<L1GtPrescaleFactors, L1GtPrescaleFactorsTechTrigRcd> m_l1GtPfTech;
0048 edm::ESGetToken<L1GtTriggerMask, L1GtTriggerMaskAlgoTrigRcd> m_l1GtTmAlgo;
0049 edm::ESGetToken<L1GtTriggerMask, L1GtTriggerMaskTechTrigRcd> m_l1GtTmTech;
0050 edm::ESGetToken<L1GtTriggerMask, L1GtTriggerMaskVetoAlgoTrigRcd> m_l1GtTmVetoAlgo;
0051 edm::ESGetToken<L1GtTriggerMask, L1GtTriggerMaskVetoTechTrigRcd> m_l1GtTmVetoTech;
0052 };
0053
0054 private:
0055
0056 void beginRun(const edm::Run&, const edm::EventSetup&) override;
0057
0058
0059 void beginLuminosityBlock(const edm::LuminosityBlock&, const edm::EventSetup&) override;
0060
0061
0062 void analyze(const edm::Event&, const edm::EventSetup&) override;
0063
0064
0065 void endLuminosityBlock(const edm::LuminosityBlock&, const edm::EventSetup&) override;
0066
0067
0068 void endRun(const edm::Run&, const edm::EventSetup&) override;
0069
0070 private:
0071
0072 void retrieveL1EventSetup(const edm::EventSetup&, const Tokens&);
0073
0074
0075 void printL1EventSetup();
0076
0077 private:
0078
0079
0080
0081 bool m_testerPrescaleFactors;
0082 bool m_testerTriggerMask;
0083 bool m_testerTriggerVetoMask;
0084
0085
0086 bool m_retrieveInBeginRun;
0087 bool m_retrieveInBeginLuminosityBlock;
0088 bool m_retrieveInAnalyze;
0089
0090
0091 bool m_printInBeginRun;
0092 bool m_printInBeginLuminosityBlock;
0093 bool m_printInAnalyze;
0094
0095
0096 int m_printOutput;
0097
0098 private:
0099
0100 const L1GtPrescaleFactors* m_l1GtPfAlgo;
0101 const L1GtPrescaleFactors* m_l1GtPfTech;
0102
0103
0104 const L1GtTriggerMask* m_l1GtTmAlgo;
0105 const L1GtTriggerMask* m_l1GtTmTech;
0106
0107 const L1GtTriggerMask* m_l1GtTmVetoAlgo;
0108 const L1GtTriggerMask* m_l1GtTmVetoTech;
0109
0110 Tokens m_run;
0111 Tokens m_lumi;
0112 Tokens m_event;
0113 };
0114
0115 #endif