ATLAS Offline Software
PyAthenaAlg.h
Go to the documentation of this file.
1 
3 /*
4  Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 // PyAthenaAlg.h
8 // Header file for class PyAthena::Alg
9 // Author: S.Binet<binet@cern.ch>
11 #ifndef ATHENAPYTHON_PYATHENAALG_H
12 #define ATHENAPYTHON_PYATHENAALG_H
13 
14 // STL includes
15 #include <string>
16 
17 // FrameWork includes
21 
22 // Forward declaration
23 // Python
24 struct _object;
25 typedef _object PyObject;
26 
27 namespace PyAthena {
28 
29 typedef ::AthAlgorithm AlgBase_t;
30 
31 class ATLAS_NOT_THREAD_SAFE Alg : virtual public ::IPyComponent,
32  public AlgBase_t
33 {
35  // Public methods:
37  public:
38 
40  Alg( const std::string& name, ISvcLocator* pSvcLocator );
41 
43  virtual ~Alg();
44 
45  // Framework's Hooks
46  virtual StatusCode initialize() override;
47  virtual StatusCode reinitialize() override;
48  virtual StatusCode start() override;
49  virtual StatusCode execute() override;
50  virtual StatusCode stop() override;
51  virtual StatusCode finalize() override;
52 
53  virtual StatusCode sysInitialize() override;
54 
56  // Const methods:
58 
63  virtual const char* typeName() const override;
64 
66  // Non-const methods:
68 
71  virtual PyObject* self() override { return m_self; }
72 
74  // Protected methods:
76  protected:
77 
80  virtual bool setPyAttr( PyObject* pyobj ) override;
81 
83  // Private data:
85  private:
86 
88  Alg();
89 
91  // Protected data:
93  protected:
94 
97 
98 };
99 
100 
101 } //> end namespace PyAthena
102 
103 #endif //> ATHENAPYTHON_PYATHENAALG_H
PyAthena::Alg::m_self
PyObject * m_self
Pointer to self (from the python world)
Definition: PyAthenaAlg.h:96
PyAthena::AlgBase_t
::AthAlgorithm AlgBase_t
Definition: PyAthenaAlg.h:29
python.tests.PyTestsLib.finalize
def finalize(self)
_info( "content of StoreGate..." ) self.sg.dump()
Definition: PyTestsLib.py:50
PyObject
_object PyObject
Definition: PyAthenaAlg.h:24
initialize
void initialize()
Definition: run_EoverP.cxx:894
mergePhysValFiles.start
start
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:14
PixelModuleFeMask_create_db.stop
int stop
Definition: PixelModuleFeMask_create_db.py:76
LArG4FSStartPointFilterLegacy.execute
execute
Definition: LArG4FSStartPointFilterLegacy.py:20
AthAlgorithm.h
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
PyAthena::Alg::Alg
Alg()
Default constructor:
IPyComponent
Definition: IPyComponent.h:31
AthAlgorithm
Definition: AthAlgorithm.h:47
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
IPyComponent.h
PyAthena
Definition: IPyComponent.h:28
ReadCalibFromCool.typeName
typeName
Definition: ReadCalibFromCool.py:477
PyAthena::Alg
Definition: PyAthenaAlg.h:33
checker_macros.h
Define macros for attributes used to control the static checker.
PyObject
_object PyObject
Definition: IPyComponent.h:26
PyAthena::ATLAS_NOT_THREAD_SAFE
StatusCode callPyMethod ATLAS_NOT_THREAD_SAFE(PyObject *self, const char *method, PyObject *arg=nullptr)
call the python method