ATLAS Offline Software
SelectionNameSvc.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 
7 
8 #ifndef SYSTEMATICS_HANDLES__SELECTION_NAME_SVC_H
9 #define SYSTEMATICS_HANDLES__SELECTION_NAME_SVC_H
10 
11 #include <AsgServices/AsgService.h>
14 #include <PATCore/AcceptInfo.h>
18 #include <mutex>
19 #include <unordered_map>
20 
21 namespace CP
22 {
24 
25  class SelectionNameSvc final : public asg::AsgService,
26  virtual public ISelectionNameSvc
27  {
28  //
29  // public interface
30  //
31 
37  public:
38  SelectionNameSvc (const std::string& name,
39  ISvcLocator* pSvcLocator);
40 
41 
42 
43  //
44  // inherited interface
45  //
46 
47  public:
48 
49  virtual StatusCode initialize () override;
50  virtual StatusCode addAcceptInfo (const std::string& objectName, const std::string& decorName,
51  const asg::AcceptInfo& acceptInfo) override;
52  virtual const asg::AcceptInfo* getAcceptInfo (const std::string& objectName,
53  const std::string& decorName) const override;
54 
55 
56 
57  //
58  // private interface
59  //
60 
61  private:
62 
66  ServiceHandle<ISystematicsSvc> m_sysSvc {"SystematicsSvc", "SelectionNameSvc"};
67 
69  std::unordered_map<std::string, std::unordered_map<std::string, asg::AcceptInfo>> m_acceptInfoMap;
70  };
71 }
72 
73 #endif
AsgService.h
SystematicSet.h
CP::ISelectionNameSvc
the interface for the central systematics service
Definition: ISelectionNameSvc.h:27
CP
Select isolated Photons, Electrons and Muons.
Definition: Control/xAODRootAccess/xAODRootAccess/TEvent.h:48
ISystematicsSvc.h
CP::SelectionNameSvc::m_sysSvc
ServiceHandle< ISystematicsSvc > m_sysSvc
the ISystematicsSvc we use
Definition: SelectionNameSvc.h:66
asg::AcceptInfo
Definition: AcceptInfo.h:28
asg::AsgService
Base class for the dual-use service implementation classes.
Definition: AsgService.h:43
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ISelectionNameSvc.h
CP::SelectionNameSvc::getAcceptInfo
virtual const asg::AcceptInfo * getAcceptInfo(const std::string &objectName, const std::string &decorName) const override
Definition: SelectionNameSvc.cxx:70
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
ServiceHandle.h
AcceptInfo.h
CP::SelectionNameSvc::m_acceptInfoMap
std::unordered_map< std::string, std::unordered_map< std::string, asg::AcceptInfo > > m_acceptInfoMap
the map of AcceptInfo objects
Definition: SelectionNameSvc.h:69
CP::SelectionNameSvc::addAcceptInfo
virtual StatusCode addAcceptInfo(const std::string &objectName, const std::string &decorName, const asg::AcceptInfo &acceptInfo) override
Definition: SelectionNameSvc.cxx:48
CP::SelectionNameSvc::initialize
virtual StatusCode initialize() override
set up/tear down functions
Definition: SelectionNameSvc.cxx:39
CP::SelectionNameSvc
the canonical implementation of ISelectionNameSvc
Definition: SelectionNameSvc.h:27
CP::SelectionNameSvc::SelectionNameSvc
SelectionNameSvc(const std::string &name, ISvcLocator *pSvcLocator)
standard constructor
Definition: SelectionNameSvc.cxx:28
checker_macros.h
Define macros for attributes used to control the static checker.
ServiceHandle
Definition: ClusterMakerTool.h:37