#include <L1GtPrescaleFactorsAndMasksTester.h>
Public Member Functions | |
L1GtPrescaleFactorsAndMasksTester (const edm::ParameterSet &) | |
virtual | ~L1GtPrescaleFactorsAndMasksTester () |
Private Member Functions | |
void | analyze (const edm::Event &, const edm::EventSetup &) |
analyze | |
void | beginJob () |
begin job | |
void | beginLuminosityBlock (const edm::LuminosityBlock &, const edm::EventSetup &) |
begin luminosity block | |
void | beginRun (const edm::Run &, const edm::EventSetup &) |
begin run | |
void | endJob () |
end job | |
void | endLuminosityBlock (const edm::LuminosityBlock &, const edm::EventSetup &) |
end luminosity block | |
void | endRun (const edm::Run &, const edm::EventSetup &) |
end run | |
void | printL1EventSetup (const edm::EventSetup &) |
print the requred records | |
void | retrieveL1EventSetup (const edm::EventSetup &) |
retrieve all the relevant L1 trigger event setup records | |
Private Attributes | |
const L1GtPrescaleFactors * | m_l1GtPfAlgo |
prescale factors | |
const L1GtPrescaleFactors * | m_l1GtPfTech |
const L1GtTriggerMask * | m_l1GtTmAlgo |
trigger masks & veto masks | |
const L1GtTriggerMask * | m_l1GtTmTech |
const L1GtTriggerMask * | m_l1GtTmVetoAlgo |
const L1GtTriggerMask * | m_l1GtTmVetoTech |
bool | m_printInAnalyze |
bool | m_printInBeginLuminosityBlock |
bool | m_printInBeginRun |
print the records in beginRun, beginLuminosityBlock, analyze, respectively | |
int | m_printOutput |
print output | |
bool | m_retrieveInAnalyze |
bool | m_retrieveInBeginLuminosityBlock |
bool | m_retrieveInBeginRun |
retrieve the records in beginRun, beginLuminosityBlock, analyze, respectively | |
bool | m_testerPrescaleFactors |
input parameters | |
bool | m_testerTriggerMask |
bool | m_testerTriggerVetoMask |
Description: test analyzer for L1 GT prescale factors and masks.
Implementation: <TODO: enter implementation details>
$Date$ $Revision$
Definition at line 35 of file L1GtPrescaleFactorsAndMasksTester.h.
L1GtPrescaleFactorsAndMasksTester::L1GtPrescaleFactorsAndMasksTester | ( | const edm::ParameterSet & | parSet | ) | [explicit] |
Definition at line 52 of file L1GtPrescaleFactorsAndMasksTester.cc.
: m_testerPrescaleFactors( parSet.getParameter<bool> ("TesterPrescaleFactors")), m_testerTriggerMask(parSet.getParameter<bool> ("TesterTriggerMask")), m_testerTriggerVetoMask( parSet.getParameter<bool> ("TesterTriggerVetoMask")), m_retrieveInBeginRun( parSet.getParameter<bool> ("RetrieveInBeginRun")), m_retrieveInBeginLuminosityBlock( parSet.getParameter<bool> ("RetrieveInBeginLuminosityBlock")), m_retrieveInAnalyze(parSet.getParameter<bool> ("RetrieveInAnalyze")), m_printInBeginRun(parSet.getParameter<bool> ("PrintInBeginRun")), m_printInBeginLuminosityBlock( parSet.getParameter<bool> ("PrintInBeginLuminosityBlock")), m_printInAnalyze(parSet.getParameter<bool> ("PrintInAnalyze")), m_printOutput(parSet.getUntrackedParameter<int> ("PrintOutput", 3)) { // empty }
L1GtPrescaleFactorsAndMasksTester::~L1GtPrescaleFactorsAndMasksTester | ( | ) | [virtual] |
Definition at line 73 of file L1GtPrescaleFactorsAndMasksTester.cc.
{
// empty
}
void L1GtPrescaleFactorsAndMasksTester::analyze | ( | const edm::Event & | iEvent, |
const edm::EventSetup & | evSetup | ||
) | [private, virtual] |
analyze
Implements edm::EDAnalyzer.
Definition at line 111 of file L1GtPrescaleFactorsAndMasksTester.cc.
References m_printInAnalyze, m_retrieveInAnalyze, printL1EventSetup(), and retrieveL1EventSetup().
{ if (m_retrieveInAnalyze) { retrieveL1EventSetup(evSetup); } if (m_printInAnalyze) { printL1EventSetup(evSetup); } }
void L1GtPrescaleFactorsAndMasksTester::beginJob | ( | void | ) | [private, virtual] |
begin job
Reimplemented from edm::EDAnalyzer.
Definition at line 78 of file L1GtPrescaleFactorsAndMasksTester.cc.
{ }
void L1GtPrescaleFactorsAndMasksTester::beginLuminosityBlock | ( | const edm::LuminosityBlock & | iLumiBlock, |
const edm::EventSetup & | evSetup | ||
) | [private, virtual] |
begin luminosity block
Reimplemented from edm::EDAnalyzer.
Definition at line 97 of file L1GtPrescaleFactorsAndMasksTester.cc.
References m_printInBeginLuminosityBlock, m_retrieveInBeginLuminosityBlock, printL1EventSetup(), and retrieveL1EventSetup().
{ if (m_retrieveInBeginLuminosityBlock) { retrieveL1EventSetup(evSetup); } if (m_printInBeginLuminosityBlock) { printL1EventSetup(evSetup); } }
void L1GtPrescaleFactorsAndMasksTester::beginRun | ( | const edm::Run & | iRun, |
const edm::EventSetup & | evSetup | ||
) | [private, virtual] |
begin run
Reimplemented from edm::EDAnalyzer.
Definition at line 83 of file L1GtPrescaleFactorsAndMasksTester.cc.
References m_printInBeginRun, m_retrieveInBeginRun, printL1EventSetup(), and retrieveL1EventSetup().
{ if (m_retrieveInBeginRun) { retrieveL1EventSetup(evSetup); } if (m_printInBeginRun) { printL1EventSetup(evSetup); } }
void L1GtPrescaleFactorsAndMasksTester::endJob | ( | void | ) | [private, virtual] |
end job
Reimplemented from edm::EDAnalyzer.
Definition at line 137 of file L1GtPrescaleFactorsAndMasksTester.cc.
{ }
void L1GtPrescaleFactorsAndMasksTester::endLuminosityBlock | ( | const edm::LuminosityBlock & | iLumiBlock, |
const edm::EventSetup & | evSetup | ||
) | [private, virtual] |
end luminosity block
Reimplemented from edm::EDAnalyzer.
Definition at line 125 of file L1GtPrescaleFactorsAndMasksTester.cc.
{ }
void L1GtPrescaleFactorsAndMasksTester::endRun | ( | const edm::Run & | iRun, |
const edm::EventSetup & | evSetup | ||
) | [private, virtual] |
end run
Reimplemented from edm::EDAnalyzer.
Definition at line 131 of file L1GtPrescaleFactorsAndMasksTester.cc.
{ }
void L1GtPrescaleFactorsAndMasksTester::printL1EventSetup | ( | const edm::EventSetup & | evSetup | ) | [private] |
print the requred records
Definition at line 181 of file L1GtPrescaleFactorsAndMasksTester.cc.
References gather_cfg::cout, LogTrace, m_l1GtPfAlgo, m_l1GtPfTech, m_l1GtTmAlgo, m_l1GtTmTech, m_l1GtTmVetoAlgo, m_l1GtTmVetoTech, m_printOutput, m_testerPrescaleFactors, m_testerTriggerMask, m_testerTriggerVetoMask, L1GtPrescaleFactors::print(), and L1GtTriggerMask::print().
Referenced by analyze(), beginLuminosityBlock(), and beginRun().
{ // define an output stream to print into // it can then be directed to whatever log level is desired std::ostringstream myCout; if (m_testerPrescaleFactors) { myCout << "\nL1 GT prescale factors for algorithm triggers" << std::endl; m_l1GtPfAlgo->print(myCout); myCout << "\nL1 GT prescale factors for technical triggers" << std::endl; m_l1GtPfTech->print(myCout); } // if (m_testerTriggerMask) { myCout << "\nL1 GT trigger masks for algorithm triggers" << std::endl; m_l1GtTmAlgo->print(myCout); myCout << "\nL1 GT trigger masks for technical triggers" << std::endl; m_l1GtTmTech->print(myCout); } // if (m_testerTriggerVetoMask) { myCout << "\nL1 GT trigger veto masks for algorithm triggers" << std::endl; m_l1GtTmVetoAlgo->print(myCout); myCout << "\nL1 GT trigger veto masks for technical triggers" << std::endl; m_l1GtTmVetoTech->print(myCout); } switch (m_printOutput) { case 0: { std::cout << myCout.str() << std::endl; } break; case 1: { LogTrace("L1GtPrescaleFactorsAndMasksTester") << myCout.str() << std::endl; } break; case 2: { edm::LogVerbatim("L1GtPrescaleFactorsAndMasksTester") << myCout.str() << std::endl; } break; case 3: { edm::LogInfo("L1GtPrescaleFactorsAndMasksTester") << myCout.str(); } break; default: { myCout << "\n\n L1GtPrescaleFactorsAndMasksTester: Error - no print output = " << m_printOutput << " defined! \n Check available values in the cfi file." << "\n" << std::endl; } break; } }
void L1GtPrescaleFactorsAndMasksTester::retrieveL1EventSetup | ( | const edm::EventSetup & | evSetup | ) | [private] |
retrieve all the relevant L1 trigger event setup records
Definition at line 141 of file L1GtPrescaleFactorsAndMasksTester.cc.
References edm::EventSetup::get(), m_l1GtPfAlgo, m_l1GtPfTech, m_l1GtTmAlgo, m_l1GtTmTech, m_l1GtTmVetoAlgo, m_l1GtTmVetoTech, m_testerPrescaleFactors, m_testerTriggerMask, m_testerTriggerVetoMask, and edm::ESHandle< T >::product().
Referenced by analyze(), beginLuminosityBlock(), and beginRun().
{ if (m_testerPrescaleFactors) { // get / update the prescale factors from the EventSetup edm::ESHandle<L1GtPrescaleFactors> l1GtPfAlgo; evSetup.get<L1GtPrescaleFactorsAlgoTrigRcd> ().get(l1GtPfAlgo); m_l1GtPfAlgo = l1GtPfAlgo.product(); edm::ESHandle<L1GtPrescaleFactors> l1GtPfTech; evSetup.get<L1GtPrescaleFactorsTechTrigRcd> ().get(l1GtPfTech); m_l1GtPfTech = l1GtPfTech.product(); } if (m_testerTriggerMask) { // get / update the trigger mask from the EventSetup edm::ESHandle<L1GtTriggerMask> l1GtTmAlgo; evSetup.get<L1GtTriggerMaskAlgoTrigRcd> ().get(l1GtTmAlgo); m_l1GtTmAlgo = l1GtTmAlgo.product(); edm::ESHandle<L1GtTriggerMask> l1GtTmTech; evSetup.get<L1GtTriggerMaskTechTrigRcd> ().get(l1GtTmTech); m_l1GtTmTech = l1GtTmTech.product(); } if (m_testerTriggerVetoMask) { edm::ESHandle<L1GtTriggerMask> l1GtTmVetoAlgo; evSetup.get<L1GtTriggerMaskVetoAlgoTrigRcd> ().get(l1GtTmVetoAlgo); m_l1GtTmVetoAlgo = l1GtTmVetoAlgo.product(); edm::ESHandle<L1GtTriggerMask> l1GtTmVetoTech; evSetup.get<L1GtTriggerMaskVetoTechTrigRcd> ().get(l1GtTmVetoTech); m_l1GtTmVetoTech = l1GtTmVetoTech.product(); } }
const L1GtPrescaleFactors* L1GtPrescaleFactorsAndMasksTester::m_l1GtPfAlgo [private] |
prescale factors
Definition at line 105 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by printL1EventSetup(), and retrieveL1EventSetup().
const L1GtPrescaleFactors* L1GtPrescaleFactorsAndMasksTester::m_l1GtPfTech [private] |
Definition at line 106 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by printL1EventSetup(), and retrieveL1EventSetup().
const L1GtTriggerMask* L1GtPrescaleFactorsAndMasksTester::m_l1GtTmAlgo [private] |
trigger masks & veto masks
Definition at line 109 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by printL1EventSetup(), and retrieveL1EventSetup().
const L1GtTriggerMask* L1GtPrescaleFactorsAndMasksTester::m_l1GtTmTech [private] |
Definition at line 110 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by printL1EventSetup(), and retrieveL1EventSetup().
const L1GtTriggerMask* L1GtPrescaleFactorsAndMasksTester::m_l1GtTmVetoAlgo [private] |
Definition at line 112 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by printL1EventSetup(), and retrieveL1EventSetup().
const L1GtTriggerMask* L1GtPrescaleFactorsAndMasksTester::m_l1GtTmVetoTech [private] |
Definition at line 113 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by printL1EventSetup(), and retrieveL1EventSetup().
bool L1GtPrescaleFactorsAndMasksTester::m_printInAnalyze [private] |
Definition at line 95 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by analyze().
Definition at line 94 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by beginLuminosityBlock().
bool L1GtPrescaleFactorsAndMasksTester::m_printInBeginRun [private] |
print the records in beginRun, beginLuminosityBlock, analyze, respectively
Definition at line 93 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by beginRun().
int L1GtPrescaleFactorsAndMasksTester::m_printOutput [private] |
print output
Definition at line 98 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by printL1EventSetup().
bool L1GtPrescaleFactorsAndMasksTester::m_retrieveInAnalyze [private] |
Definition at line 90 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by analyze().
Definition at line 89 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by beginLuminosityBlock().
bool L1GtPrescaleFactorsAndMasksTester::m_retrieveInBeginRun [private] |
retrieve the records in beginRun, beginLuminosityBlock, analyze, respectively
Definition at line 88 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by beginRun().
bool L1GtPrescaleFactorsAndMasksTester::m_testerPrescaleFactors [private] |
input parameters
analyze prescale factors, trigger masks and trigger veto masks, respectively
Definition at line 83 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by printL1EventSetup(), and retrieveL1EventSetup().
bool L1GtPrescaleFactorsAndMasksTester::m_testerTriggerMask [private] |
Definition at line 84 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by printL1EventSetup(), and retrieveL1EventSetup().
bool L1GtPrescaleFactorsAndMasksTester::m_testerTriggerVetoMask [private] |
Definition at line 85 of file L1GtPrescaleFactorsAndMasksTester.h.
Referenced by printL1EventSetup(), and retrieveL1EventSetup().