CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Static Public Attributes | Protected Attributes
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 std::string kEmptyKey = ""
 
static std::string kNullKey = "NULL"
 

Protected Attributes

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

Detailed Description

Definition at line 21 of file L1TriggerKey.h.

Member Typedef Documentation

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

Definition at line 24 of file L1TriggerKey.h.

Member Enumeration Documentation

Enumerator
kCSCTF 
kDTTF 
kRPC 
kGMT 
kRCT 
kGCT 
kGT 
kTSP0 
kNumberSubsystems 

Definition at line 26 of file L1TriggerKey.h.

Constructor & Destructor Documentation

L1TriggerKey::L1TriggerKey ( )
inline

Definition at line 45 of file L1TriggerKey.h.

References i, kNullKey, kNumberSubsystems, and m_subsystemKeys.

46  {
47  for( int i = 0 ; i < kNumberSubsystems ; ++i )
48  {
50  }
51  }
int i
Definition: DBlmapReader.cc:9
std::string m_subsystemKeys[kNumberSubsystems]
Definition: L1TriggerKey.h:109
static std::string kNullKey
Definition: L1TriggerKey.h:40

Member Function Documentation

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

Definition at line 54 of file L1TriggerKey.h.

References combine::key, kNullKey, and m_recordToKey.

Referenced by L1TriggerKeyDummyProd::L1TriggerKeyDummyProd().

55  { m_recordToKey.insert (std::make_pair (record + "@" + type, key.empty() ? kNullKey : key)); }
type
Definition: HCALResponse.h:21
JetCorrectorParameters::Record record
Definition: classes.h:13
RecordToKey m_recordToKey
Definition: L1TriggerKey.h:104
list key
Definition: combine.py:13
static std::string kNullKey
Definition: L1TriggerKey.h:40
void L1TriggerKey::add ( const RecordToKey map)
inline

Definition at line 57 of file L1TriggerKey.h.

References kNullKey, and m_recordToKey.

58  {
59  for( RecordToKey::const_iterator itr = map.begin() ;
60  itr != map.end() ;
61  ++itr )
62  {
63  m_recordToKey.insert( std::make_pair( itr->first, itr->second.empty() ? kNullKey : itr->second ) ) ;
64  }
65  }
RecordToKey m_recordToKey
Definition: L1TriggerKey.h:104
dictionary map
Definition: Association.py:205
static std::string kNullKey
Definition: L1TriggerKey.h:40
std::string L1TriggerKey::get ( const std::string &  record,
const std::string &  type 
) const
inline

Definition at line 76 of file L1TriggerKey.h.

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

Referenced by Options.Options::__getitem__(), betterConfigParser.BetterConfigParser::__updateDict(), betterConfigParser.BetterConfigParser::getCompares(), betterConfigParser.BetterConfigParser::getGeneral(), and betterConfigParser.BetterConfigParser::getResultingSection().

77  {
78  RecordToKey::const_iterator it = m_recordToKey.find (record + "@" + type);
79  if (it == m_recordToKey.end ())
80  return std::string ();
81  else
82  return it->second == kNullKey ? kEmptyKey : it->second ;
83  }
type
Definition: HCALResponse.h:21
JetCorrectorParameters::Record record
Definition: classes.h:13
RecordToKey m_recordToKey
Definition: L1TriggerKey.h:104
static std::string kEmptyKey
Definition: L1TriggerKey.h:42
static std::string kNullKey
Definition: L1TriggerKey.h:40
const RecordToKey& L1TriggerKey::recordToKeyMap ( ) const
inline

Definition at line 92 of file L1TriggerKey.h.

References m_recordToKey.

Referenced by L1CondDBIOVWriter::analyze().

93  { return m_recordToKey ; }
RecordToKey m_recordToKey
Definition: L1TriggerKey.h:104
void L1TriggerKey::setSubsystemKey ( L1Subsystems  subsystem,
const std::string &  key 
)
inline

Definition at line 70 of file L1TriggerKey.h.

References combine::key, kNullKey, m_subsystemKeys, and hcal_dqm_sourceclient-file_cfg::subsystem.

Referenced by L1TriggerKeyDummyProd::L1TriggerKeyDummyProd().

71  { m_subsystemKeys[ subsystem ] = key.empty() ? kNullKey : key ; }
std::string m_subsystemKeys[kNumberSubsystems]
Definition: L1TriggerKey.h:109
list key
Definition: combine.py:13
static std::string kNullKey
Definition: L1TriggerKey.h:40
void L1TriggerKey::setTSCKey ( const std::string &  tscKey)
inline

Definition at line 67 of file L1TriggerKey.h.

References m_tscKey, and tscKey().

Referenced by L1TriggerKeyDummyProd::L1TriggerKeyDummyProd().

68  { m_tscKey = tscKey ; }
std::string m_tscKey
Definition: L1TriggerKey.h:108
const std::string & tscKey() const
Definition: L1TriggerKey.h:85
const std::string& L1TriggerKey::subsystemKey ( L1Subsystems  subsystem) const
inline

Definition at line 88 of file L1TriggerKey.h.

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

std::string m_subsystemKeys[kNumberSubsystems]
Definition: L1TriggerKey.h:109
static std::string kEmptyKey
Definition: L1TriggerKey.h:42
static std::string kNullKey
Definition: L1TriggerKey.h:40
const std::string& L1TriggerKey::tscKey ( ) const
inline

Definition at line 85 of file L1TriggerKey.h.

References m_tscKey.

Referenced by setTSCKey().

86  { return m_tscKey ; }
std::string m_tscKey
Definition: L1TriggerKey.h:108

Member Data Documentation

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

Definition at line 42 of file L1TriggerKey.h.

Referenced by get(), and subsystemKey().

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

Definition at line 104 of file L1TriggerKey.h.

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

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

Definition at line 109 of file L1TriggerKey.h.

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

std::string L1TriggerKey::m_tscKey
protected

Definition at line 108 of file L1TriggerKey.h.

Referenced by setTSCKey(), and tscKey().