ATLAS Offline Software
HLTIdentifier.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 
7 
8 
9 HLT::Identifier::Identifier( const std::string& stringID )
10  : m_id( TrigConf::HLTUtils::string2hash( stringID, "Identifier" ) ) {}
11 
12 std::string HLT::Identifier::name() const {
13  return TrigConf::HLTUtils::hash2string( numeric(), "Identifier" );
14 }
15 
16 MsgStream& operator<< ( MsgStream& m, const HLT::Identifier& id ) {
17  m << id.name() << " ID#" << id.numeric();
18  return m;
19 }
20 
21 HLT::Identifier HLT::Identifier::fromToolName( const std::string& tname ) {
22  return HLT::Identifier( tname.substr( tname.find('.') + 1 ) );
23 }
HLT::Identifier::Identifier
Identifier(const std::string &stringID)
constructs identifier from human redable name
Definition: HLTIdentifier.cxx:9
HLT::operator<<
MsgStream & operator<<(MsgStream &m, const Navigation &nav)
Definition: Navigation.cxx:168
TrigConf
Forward iterator to traverse the main components of the trigger configuration.
Definition: Config.h:22
HLTUtils.h
HLT::Identifier
Definition: TrigCompositeUtils/TrigCompositeUtils/HLTIdentifier.h:19
TrigConf::HLTUtils::hash2string
static const std::string hash2string(HLTHash, const std::string &category="TE")
hash function translating identifiers into names (via internal dictionary)
HLT::Identifier::fromToolName
static HLT::Identifier fromToolName(const std::string &tname)
Definition: HLTIdentifier.cxx:21
HLTUtils.string2hash
def string2hash(string)
Definition: HLTUtils.py:5
HLTIdentifier.h
HLT::Identifier::name
std::string name() const
reports human redable name
Definition: HLTIdentifier.cxx:12
HLTUtils
Definition: HLTUtils.py:1
python.SystemOfUnits.m
float m
Definition: SystemOfUnits.py:106