#include <LumiSummaryRunHeader.h>
Public Types | |
typedef std::vector< std::string > | vstring_t |
Public Member Functions | |
unsigned int | getHLTIndex (const std::string &name) const |
Get index of given HLT path-name. Returns -1 if not found. | |
std::string | getHLTName (unsigned int idx) const |
Get HLT name at given position. | |
const vstring_t & | getHLTNames (vstring_t &hltnames) const |
Get HLT name vector. | |
unsigned int | getL1Index (const std::string &name) const |
Get index of given L1 trigger-name. Returns -1 if not found. | |
std::string | getL1Name (unsigned int idx) const |
Get L1 name at given position. | |
const vstring_t & | getL1Names (vstring_t &l1names) const |
Get L1 name vector. | |
bool | isProductEqual (LumiSummaryRunHeader const &o) const |
Product compare function. | |
LumiSummaryRunHeader (vstring_t &l1names, vstring_t &hltnames) | |
LumiSummaryRunHeader () | |
Default constructor. | |
void | setHLTNames (const vstring_t &hltnames) |
Set HLT name vector. | |
void | setL1Names (const vstring_t &l1names) |
Set L1 name vector. | |
void | swapHLTNames (vstring_t &hltnames) |
Swap HLT name vector. | |
void | swapL1Names (vstring_t &l1names) |
Swap L1 name vector. | |
~LumiSummaryRunHeader () | |
Destructor. | |
Private Attributes | |
vstring_t | m_hltNames |
vstring_t | m_l1Names |
LumiSummaryRunHeader contains LumiSummary data which remains valid during the whole run.
1. Vectors of L1 and HLT trigger / path names. LumiSummary uses integer indices into these two vectors to minimize disk-usage in highly selective skim files.
Definition at line 22 of file LumiSummaryRunHeader.h.
typedef std::vector<std::string> LumiSummaryRunHeader::vstring_t |
Definition at line 25 of file LumiSummaryRunHeader.h.
LumiSummaryRunHeader::LumiSummaryRunHeader | ( | ) | [inline] |
Constructor with names. Vectors are swapped so they are empty on return.
Definition at line 5 of file LumiSummaryRunHeader.cc.
References m_hltNames, and m_l1Names.
{ m_l1Names.swap(l1names); m_hltNames.swap(hltnames); }
LumiSummaryRunHeader::~LumiSummaryRunHeader | ( | ) | [inline] |
unsigned int LumiSummaryRunHeader::getHLTIndex | ( | const std::string & | name | ) | const |
Get index of given HLT path-name. Returns -1 if not found.
Definition at line 50 of file LumiSummaryRunHeader.cc.
References i, m_hltNames, and findQualityFiles::size.
{ const unsigned int size = m_hltNames.size(); for (unsigned int i = 0; i < size; ++i) { if (m_hltNames[i] == name) return i; } return -1; }
std::string LumiSummaryRunHeader::getHLTName | ( | unsigned int | idx | ) | const [inline] |
Get HLT name at given position.
Definition at line 62 of file LumiSummaryRunHeader.h.
References m_hltNames.
{ return m_hltNames.at(idx); }
Get HLT name vector.
Definition at line 68 of file LumiSummaryRunHeader.h.
References m_hltNames.
{ return m_hltNames; }
unsigned int LumiSummaryRunHeader::getL1Index | ( | const std::string & | name | ) | const |
Get index of given L1 trigger-name. Returns -1 if not found.
Definition at line 40 of file LumiSummaryRunHeader.cc.
References i, m_l1Names, and findQualityFiles::size.
std::string LumiSummaryRunHeader::getL1Name | ( | unsigned int | idx | ) | const [inline] |
Get L1 name at given position.
Definition at line 59 of file LumiSummaryRunHeader.h.
References m_l1Names.
{ return m_l1Names.at(idx); }
Get L1 name vector.
Definition at line 65 of file LumiSummaryRunHeader.h.
References m_l1Names.
{ return m_l1Names; }
bool LumiSummaryRunHeader::isProductEqual | ( | LumiSummaryRunHeader const & | o | ) | const |
Product compare function.
Definition at line 11 of file LumiSummaryRunHeader.cc.
References m_hltNames, and m_l1Names.
{ return m_l1Names == o.m_l1Names && m_hltNames == o.m_hltNames; }
void LumiSummaryRunHeader::setHLTNames | ( | const vstring_t & | hltnames | ) |
Set HLT name vector.
Definition at line 23 of file LumiSummaryRunHeader.cc.
References m_hltNames.
{ m_hltNames.assign(hltnames.begin(), hltnames.end()); }
void LumiSummaryRunHeader::setL1Names | ( | const vstring_t & | l1names | ) |
Set L1 name vector.
Definition at line 18 of file LumiSummaryRunHeader.cc.
References m_l1Names.
{ m_l1Names.assign(l1names.begin(), l1names.end()); }
void LumiSummaryRunHeader::swapHLTNames | ( | vstring_t & | hltnames | ) |
Swap HLT name vector.
Definition at line 33 of file LumiSummaryRunHeader.cc.
References m_hltNames.
{ m_hltNames.swap(hltnames); }
void LumiSummaryRunHeader::swapL1Names | ( | vstring_t & | l1names | ) |
Swap L1 name vector.
Definition at line 28 of file LumiSummaryRunHeader.cc.
References m_l1Names.
{ m_l1Names.swap(l1names); }
vstring_t LumiSummaryRunHeader::m_hltNames [private] |
Definition at line 80 of file LumiSummaryRunHeader.h.
Referenced by getHLTIndex(), getHLTName(), getHLTNames(), isProductEqual(), LumiSummaryRunHeader(), setHLTNames(), and swapHLTNames().
vstring_t LumiSummaryRunHeader::m_l1Names [private] |
Definition at line 79 of file LumiSummaryRunHeader.h.
Referenced by getL1Index(), getL1Name(), getL1Names(), isProductEqual(), LumiSummaryRunHeader(), setL1Names(), and swapL1Names().