CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Types | Public Member Functions | Static Public Attributes | Protected Attributes | Private Member Functions | Friends
L1TriggerKey Class Reference

#include <L1TriggerKey.h>

Public Types

enum  L1Subsystems {
  kCSCTF, kDTTF, kRPC, kGMT,
  kRCT, kGCT, kGT, kTSP0,
  kNumberSubsystems
}
 
typedef std::map< std::string,
std::string > 
RecordToKey
 

Public Member Functions

void add (const std::string &record, const std::string &type, const std::string &key)
 
void add (const RecordToKey &map)
 
std::string get (const std::string &record, const std::string &type) const
 
 L1TriggerKey ()
 
const RecordToKeyrecordToKeyMap () const
 
void setSubsystemKey (L1Subsystems subsystem, const std::string &key)
 
void setTSCKey (const std::string &tscKey)
 
const std::string & subsystemKey (L1Subsystems subsystem) const
 
const std::string & tscKey () const
 

Static Public Attributes

static const std::string kEmptyKey = ""
 
static const std::string kNullKey = "NULL"
 

Protected Attributes

RecordToKey m_recordToKey
 
std::string m_subsystemKeys [kNumberSubsystems]
 
std::string m_tscKey
 

Private Member Functions

template<class Archive >
void serialize (Archive &ar, const unsigned int version)
 

Friends

class boost::serialization::access
 
template<typename CondSerializationT , typename Enabled >
struct cond::serialization::access
 

Detailed Description

Definition at line 23 of file L1TriggerKey.h.

Member Typedef Documentation

typedef std::map<std::string, std::string> L1TriggerKey::RecordToKey

Definition at line 25 of file L1TriggerKey.h.

Member Enumeration Documentation

Constructor & Destructor Documentation

L1TriggerKey::L1TriggerKey ( )
inline

Definition at line 35 of file L1TriggerKey.h.

References mps_fire::i, kNullKey, kNumberSubsystems, and m_subsystemKeys.

35  {
36  for (int i = 0; i < kNumberSubsystems; ++i) {
38  }
39  }
static const std::string kNullKey
Definition: L1TriggerKey.h:30
std::string m_subsystemKeys[kNumberSubsystems]
Definition: L1TriggerKey.h:91

Member Function Documentation

void L1TriggerKey::add ( const std::string &  record,
const std::string &  type,
const std::string &  key 
)
inline

Definition at line 42 of file L1TriggerKey.h.

References submitPVResolutionJobs::key, kNullKey, and m_recordToKey.

Referenced by L1TriggerKeyDummyProd::L1TriggerKeyDummyProd(), counter.Counter::register(), SequenceTypes.Task::remove(), and SequenceTypes.Task::replace().

42  {
43  m_recordToKey.insert(std::make_pair(record + "@" + type, key.empty() ? kNullKey : key));
44  }
static const std::string kNullKey
Definition: L1TriggerKey.h:30
RecordToKey m_recordToKey
Definition: L1TriggerKey.h:87
tuple key
prepare the HTCondor submission files and eventually submit them
void L1TriggerKey::add ( const RecordToKey map)
inline

Definition at line 46 of file L1TriggerKey.h.

References kNullKey, and m_recordToKey.

Referenced by counter.Counter::register(), SequenceTypes.Task::remove(), and SequenceTypes.Task::replace().

46  {
47  for (RecordToKey::const_iterator itr = map.begin(); itr != map.end(); ++itr) {
48  m_recordToKey.insert(std::make_pair(itr->first, itr->second.empty() ? kNullKey : itr->second));
49  }
50  }
static const std::string kNullKey
Definition: L1TriggerKey.h:30
RecordToKey m_recordToKey
Definition: L1TriggerKey.h:87
std::string L1TriggerKey::get ( const std::string &  record,
const std::string &  type 
) const
inline

Definition at line 61 of file L1TriggerKey.h.

References kEmptyKey, kNullKey, m_recordToKey, GlobalPosition_Frontier_DevDB_cff::record, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by Options.Options::__getitem__(), betterConfigParser.BetterConfigParser::__updateDict(), submitPVValidationJobs.BetterConfigParser::__updateDict(), util.rrapi.RRApi::columns(), rrapi.RRApi::columns(), rrapi.RRApi::count(), util.rrapi.RRApi::count(), rrapi.RRApi::data(), util.rrapi.RRApi::data(), betterConfigParser.BetterConfigParser::getCompares(), betterConfigParser.BetterConfigParser::getGeneral(), betterConfigParser.BetterConfigParser::getResultingSection(), submitPVValidationJobs.BetterConfigParser::getResultingSection(), util.rrapi.RRApi::report(), rrapi.RRApi::report(), rrapi.RRApi::reports(), util.rrapi.RRApi::reports(), rrapi.RRApi::tables(), util.rrapi.RRApi::tables(), util.rrapi.RRApi::tags(), rrapi.RRApi::tags(), rrapi.RRApi::templates(), util.rrapi.RRApi::templates(), util.rrapi.RRApi::workspaces(), and rrapi.RRApi::workspaces().

61  {
62  RecordToKey::const_iterator it = m_recordToKey.find(record + "@" + type);
63  if (it == m_recordToKey.end())
64  return std::string();
65  else
66  return it->second == kNullKey ? kEmptyKey : it->second;
67  }
static const std::string kEmptyKey
Definition: L1TriggerKey.h:32
static const std::string kNullKey
Definition: L1TriggerKey.h:30
RecordToKey m_recordToKey
Definition: L1TriggerKey.h:87
const RecordToKey& L1TriggerKey::recordToKeyMap ( ) const
inline

Definition at line 76 of file L1TriggerKey.h.

References m_recordToKey.

Referenced by L1CondDBIOVWriter::analyze().

76 { return m_recordToKey; }
RecordToKey m_recordToKey
Definition: L1TriggerKey.h:87
template<class Archive >
void L1TriggerKey::serialize ( Archive &  ar,
const unsigned int  version 
)
private
void L1TriggerKey::setSubsystemKey ( L1Subsystems  subsystem,
const std::string &  key 
)
inline

Definition at line 54 of file L1TriggerKey.h.

References submitPVResolutionJobs::key, kNullKey, m_subsystemKeys, and hcal_dqm_sourceclient-live_cfg::subsystem.

Referenced by L1TriggerKeyDummyProd::L1TriggerKeyDummyProd().

54  {
55  m_subsystemKeys[subsystem] = key.empty() ? kNullKey : key;
56  }
static const std::string kNullKey
Definition: L1TriggerKey.h:30
std::string m_subsystemKeys[kNumberSubsystems]
Definition: L1TriggerKey.h:91
tuple key
prepare the HTCondor submission files and eventually submit them
void L1TriggerKey::setTSCKey ( const std::string &  tscKey)
inline

Definition at line 52 of file L1TriggerKey.h.

References m_tscKey, and tscKey().

Referenced by L1TriggerKeyDummyProd::L1TriggerKeyDummyProd().

52 { m_tscKey = tscKey; }
std::string m_tscKey
Definition: L1TriggerKey.h:90
const std::string & tscKey() const
Definition: L1TriggerKey.h:69
const std::string& L1TriggerKey::subsystemKey ( L1Subsystems  subsystem) const
inline

Definition at line 71 of file L1TriggerKey.h.

References kEmptyKey, kNullKey, m_subsystemKeys, and hcal_dqm_sourceclient-live_cfg::subsystem.

71  {
73  }
static const std::string kEmptyKey
Definition: L1TriggerKey.h:32
static const std::string kNullKey
Definition: L1TriggerKey.h:30
std::string m_subsystemKeys[kNumberSubsystems]
Definition: L1TriggerKey.h:91
const std::string& L1TriggerKey::tscKey ( ) const
inline

Definition at line 69 of file L1TriggerKey.h.

References m_tscKey.

Referenced by setTSCKey().

69 { return m_tscKey; }
std::string m_tscKey
Definition: L1TriggerKey.h:90

Friends And Related Function Documentation

friend class boost::serialization::access
friend

Definition at line 93 of file L1TriggerKey.h.

template<typename CondSerializationT , typename Enabled >
friend struct cond::serialization::access
friend

Definition at line 93 of file L1TriggerKey.h.

Member Data Documentation

const std::string L1TriggerKey::kEmptyKey = ""
static

Definition at line 32 of file L1TriggerKey.h.

Referenced by get(), and subsystemKey().

const std::string L1TriggerKey::kNullKey = "NULL"
static
RecordToKey L1TriggerKey::m_recordToKey
protected

Definition at line 87 of file L1TriggerKey.h.

Referenced by add(), get(), and recordToKeyMap().

std::string L1TriggerKey::m_subsystemKeys[kNumberSubsystems]
protected

Definition at line 91 of file L1TriggerKey.h.

Referenced by L1TriggerKey(), setSubsystemKey(), and subsystemKey().

std::string L1TriggerKey::m_tscKey
protected

Definition at line 90 of file L1TriggerKey.h.

Referenced by setTSCKey(), and tscKey().