ATLAS Offline Software
ReadExampleElectron.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef ATHENAPOOLEXAMPLEALGORITHMS_READSIMPLEELECTRON_H
6 #define ATHENAPOOLEXAMPLEALGORITHMS_READSIMPLEELECTRON_H
7 
12 #include "GaudiKernel/ServiceHandle.h"
15 
16 class StoreGateSvc;
17 
18 namespace AthPoolEx {
19 
25  public: // Constructor and Destructor
27  ReadExampleElectron(const std::string& name, ISvcLocator* pSvcLocator);
29  virtual ~ReadExampleElectron() = default;
30 
31  public:
33  virtual StatusCode initialize() override final;
34  virtual StatusCode execute(const EventContext& ctx) const override final;
35  virtual StatusCode finalize() override final;
36 
37  private:
38  // Reading through the container of example electrons
39  SG::ReadHandleKey<xAOD::ExampleElectronContainer>
40  m_exampleElectronContainerKey{this, "ExampleElectronContainerName",
41  "TestContainer"};
42 
43  // Also want to read through '.decor1' decorations, ignoring '.decor2' for
44  // sake of demonstration see python/AthenaPoolExample_Write.py:
45  // ItemList = [ ... ,
46  // 'xAOD::ExampleElectronAuxContainer#TestContainerAux.-decor2' ]
48  this, "ExampleElectronContainerDecorKey1", "TestContainer.decor1",
49  "decorator1 key"};
50 };
51 
52 } // namespace AthPoolEx
53 
54 #endif
ReadHandleKey.h
Property holding a SG store/key/clid from which a ReadHandle is made.
ReadDecorHandleKey.h
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle is made.
SG
Forward declaration.
Definition: CaloCellPacker_400_500.h:32
AthPoolEx::ReadExampleElectron::initialize
virtual StatusCode initialize() override final
Gaudi Service Interface method implementations:
Definition: ReadExampleElectron.cxx:24
AthPoolEx::ReadExampleElectron::m_exampleElectronContainerKey
SG::ReadHandleKey< xAOD::ExampleElectronContainer > m_exampleElectronContainerKey
Definition: ReadExampleElectron.h:40
ExampleElectronContainer.h
xAOD
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
Definition: ICaloAffectedTool.h:24
AthPoolEx::ReadExampleElectron::~ReadExampleElectron
virtual ~ReadExampleElectron()=default
Destructor.
AthPoolEx::ReadExampleElectron::m_decor1Key
SG::ReadDecorHandleKey< xAOD::ExampleElectronContainer > m_decor1Key
Definition: ReadExampleElectron.h:47
AthPoolEx::ReadExampleElectron
This class provides an example for reading event data objects from Pool.
Definition: ReadExampleElectron.h:24
const
bool const RAWDATA *ch2 const
Definition: LArRodBlockPhysicsV0.cxx:560
xAOD::ExampleElectronContainer
ExampleElectronContainer_v1 ExampleElectronContainer
Definition: ExampleElectronContainer.h:11
AthReentrantAlgorithm
An algorithm that can be simultaneously executed in multiple threads.
Definition: AthReentrantAlgorithm.h:83
StoreGateSvc
The Athena Transient Store API.
Definition: StoreGateSvc.h:125
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AthPoolEx::ReadExampleElectron::ReadExampleElectron
ReadExampleElectron(const std::string &name, ISvcLocator *pSvcLocator)
Standard Service Constructor.
Definition: ReadExampleElectron.cxx:20
AthReentrantAlgorithm.h
private
#define private
Definition: DetDescrConditionsDict_dict_fixes.cxx:13
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
AthPoolEx::ReadExampleElectron::execute
virtual StatusCode execute(const EventContext &ctx) const override final
Definition: ReadExampleElectron.cxx:33
ExampleTrackContainer.h
This file contains the class definition for the ExampleTrackContainer class.
AthPoolEx
Definition: PassNoneFilter.h:16
ExampleHitContainer.h
This file contains the class definition for the ExampleHitContainer class.
SG::ReadDecorHandleKey
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle is made.
Definition: StoreGate/StoreGate/ReadDecorHandleKey.h:85
AthPoolEx::ReadExampleElectron::finalize
virtual StatusCode finalize() override final
Definition: ReadExampleElectron.cxx:71