ATLAS Offline Software
Loading...
Searching...
No Matches
xAODMenuReader.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4
5
6// Local include(s):
7#include "xAODMenuReader.h"
8
9namespace TrigConf {
10
12 ISvcLocator* svcLoc )
13 : AthAlgorithm( name, svcLoc ),
14 m_configSvc( "TrigConf::xAODConfigSvc", name ),
15 m_configTool( "TrigConf::xAODConfigTool" ) {
16
17 declareProperty( "TrigConfigSvc", m_configSvc );
18 declareProperty( "TrigConfigTool", m_configTool );
19 }
20
22
23 // Greet the user:
24 ATH_MSG_INFO( "Initialising" );
25
26 // Retrieve the needed components:
27 ATH_CHECK( m_configSvc.retrieve() );
28 ATH_CHECK( m_configTool.retrieve() );
29
30 // Reset our internal counter:
32
33 // Return gracefully:
34 return StatusCode::SUCCESS;
35 }
36
38
39 // Check if we want to do anything:
41 if( m_eventCounter > 10 ) {
42 return StatusCode::SUCCESS;
43 }
44
45 // Print some info:
46 ATH_MSG_INFO( "Configuration loaded by the service:" );
47 ATH_MSG_INFO( " SMK: " << m_configSvc->masterKey()
48 << ", L1PSK: " << m_configSvc->lvl1PrescaleKey()
49 << ", HLTPSK: " << m_configSvc->hltPrescaleKey() );
50
51 ATH_MSG_INFO( "Configuration loaded by the tool:" );
52 ATH_MSG_INFO( " SMK: " << m_configTool->masterKey()
53 << ", L1PSK: " << m_configTool->lvl1PrescaleKey()
54 << ", HLTPSK: " << m_configTool->hltPrescaleKey() );
55
56 // Return gracefully:
57 return StatusCode::SUCCESS;
58 }
59
60} // namespace TrigConf
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_INFO(x)
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
int m_eventCounter
An internal counter.
virtual StatusCode initialize()
Function initialising the algorithm.
virtual StatusCode execute()
Function executing the algorithm.
xAODMenuReader(const std::string &name, ISvcLocator *svcLoc)
Regular Algorithm constructor.
ServiceHandle< TrigConf::ITrigConfigSvc > m_configSvc
Connection to the trigger configuration service.
ToolHandle< TrigConf::ITrigConfigTool > m_configTool
Connection to the trigger configuration tool.
Forward iterator to traverse the main components of the trigger configuration.
Definition Config.h:22