ATLAS Offline Software
SCT_LinkMaskingTestAlg.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
3 */
4 
14 #include "SCT_LinkMaskingTestAlg.h"
15 
16 //Athena includes
18 
19 SCT_LinkMaskingTestAlg::SCT_LinkMaskingTestAlg(const std::string& name, ISvcLocator* pSvcLocator) :
20  AthReentrantAlgorithm(name, pSvcLocator) {
21 }
22 
23 //Initialize
25  ATH_MSG_INFO("Calling initialize");
26 
27  // Retrieve link masking tool
28  if (m_linkMaskingTool.retrieve().isFailure()) {
29  ATH_MSG_FATAL("Could not retrieve the link masking tool");
30  return StatusCode::FAILURE;
31  }
32 
33  return StatusCode::SUCCESS;
34 }
35 
36 //Execute
37 StatusCode SCT_LinkMaskingTestAlg::execute(const EventContext& ctx) const {
38 
39  ATH_MSG_INFO("Wafer 167772160 is " << (m_linkMaskingTool->isGood(Identifier{167772160}, ctx) ? "not masked" : "masked"));
40  ATH_MSG_INFO("Wafer 167773184 is " << (m_linkMaskingTool->isGood(Identifier{167773184}, ctx) ? "not masked" : "masked"));
41  ATH_MSG_INFO("Wafer 167786496 is " << (m_linkMaskingTool->isGood(Identifier{167786496}, ctx) ? "not masked" : "masked"));
42  ATH_MSG_INFO("Wafer 167787520 is " << (m_linkMaskingTool->isGood(Identifier{167787520}, ctx) ? "not masked" : "masked"));
43 
44  return StatusCode::SUCCESS;
45 }
46 
47 //Finalize
49  ATH_MSG_INFO("Calling finalize");
50  return StatusCode::SUCCESS;
51 }
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
SCT_LinkMaskingTestAlg::finalize
virtual StatusCode finalize() override
Definition: SCT_LinkMaskingTestAlg.cxx:48
AthReentrantAlgorithm
An algorithm that can be simultaneously executed in multiple threads.
Definition: AthReentrantAlgorithm.h:83
SCT_LinkMaskingTestAlg::initialize
virtual StatusCode initialize() override
Definition: SCT_LinkMaskingTestAlg.cxx:24
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
InDetHierarchy.h
SCT_LinkMaskingTestAlg::execute
virtual StatusCode execute(const EventContext &ctx) const override
Definition: SCT_LinkMaskingTestAlg.cxx:37
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
SCT_LinkMaskingTestAlg.h
SCT_LinkMaskingTestAlg::m_linkMaskingTool
ToolHandle< ISCT_ConditionsTool > m_linkMaskingTool
Definition: SCT_LinkMaskingTestAlg.h:42
Identifier
Definition: IdentifierFieldParser.cxx:14
SCT_LinkMaskingTestAlg::SCT_LinkMaskingTestAlg
SCT_LinkMaskingTestAlg(const std::string &name, ISvcLocator *pSvcLocator)
Definition: SCT_LinkMaskingTestAlg.cxx:19