ATLAS Offline Software
TriggerRegistryTool.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 
7 
8 TriggerRegistryTool::TriggerRegistryTool( const std::string& type, const std::string& name, const IInterface* parent )
10 {
11  declareInterface<ITriggerRegistryTool>(this);
12 }
13 
14 
16 {
17 }
18 
19 
21 TriggerRegistryTool::queryInterface( const InterfaceID& riid, void** ppvIf )
22 {
23  if ( riid == ITriggerRegistryTool::interfaceID() ) {
24  *ppvIf = (ITriggerRegistryTool*)this;
25  addRef();
26  return StatusCode::SUCCESS;
27  }
28 
29  return AthAlgTool::queryInterface( riid, ppvIf );
30 }
31 
32 
33 bool
34 TriggerRegistryTool::registerTriggerSelector(const TString& name, const TString& regexpr, const std::list<TString>& trigpar)
35 {
36  if (m_registry.find(name)!=m_registry.end()) {
37  ATH_MSG_WARNING ("registerTriggerSelector() :: trigger selector with name <" << name << "> already registered. Return false.");
38  return false;
39  }
40 
41  ATH_MSG_DEBUG ("registerTriggerSelector() :: trigger selector with name <" << name << "> registered.");
42  m_registry[name] = tvtPair(regexpr,trigpar);
43  return true;
44 }
45 
TriggerRegistryTool.h
This file contains the class definition for the TriggerRegistryTool class.
ITriggerRegistryTool::interfaceID
static const InterfaceID & interfaceID()
Definition: ITriggerRegistryTool.h:18
TriggerRegistryTool::TriggerRegistryTool
TriggerRegistryTool(const std::string &, const std::string &, const IInterface *)
Definition: TriggerRegistryTool.cxx:8
TriggerRegistryTool::m_registry
std::map< TString, tvtPair > m_registry
Definition: TriggerRegistryTool.h:38
ITriggerRegistryTool
Definition: ITriggerRegistryTool.h:15
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
test_pyathena.parent
parent
Definition: test_pyathena.py:15
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
tvtPair
std::pair< TString, std::list< TString > > tvtPair
Definition: ITriggerRegistryTool.h:13
TriggerRegistryTool::~TriggerRegistryTool
virtual ~TriggerRegistryTool()
Definition: TriggerRegistryTool.cxx:15
AthAlgTool
Definition: AthAlgTool.h:26
TriggerRegistryTool::registerTriggerSelector
bool registerTriggerSelector(const TString &name, const TString &regexpr, const std::list< TString > &trigpar)
register trigger
Definition: TriggerRegistryTool.cxx:34
TriggerRegistryTool::queryInterface
StatusCode queryInterface(const InterfaceID &riid, void **ppvIf)
To allow access to the ITriggerRegistryTool interface.
Definition: TriggerRegistryTool.cxx:21