ATLAS Offline Software
Loading...
Searching...
No Matches
AnaReentrantAlgorithm.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4
6
7
8#ifndef ANA_ALGORITHM__ANA_REENTRANT_ALGORITHM_H
9#define ANA_ALGORITHM__ANA_REENTRANT_ALGORITHM_H
10
11#include <AnaAlgorithm/Global.h>
12
13#ifdef XAOD_STANDALONE
15#include <AsgTools/SgTEvent.h>
16#include <memory>
17#include <vector>
18#else
21#endif
22
23class EventContext;
24class ISvcLocator;
25
26namespace EL
27{
28#ifdef XAOD_STANDALONE
29 class IWorker;
30#endif
31
44
46#ifdef XAOD_STANDALONE
47 : public asg::AsgComponent
48#else
50#endif
51 {
52 //
53 // public interface
54 //
55
66 public:
67 AnaReentrantAlgorithm (const std::string& name,
68 ISvcLocator* pSvcLocator);
69
73 public:
74 virtual ~AnaReentrantAlgorithm() noexcept;
75
76
77
78 //
79 // services interface
80 //
81
82#ifdef XAOD_STANDALONE
89 public:
90 IFilterWorker *filterWorker () const;
91
92
97 public:
98 bool filterPassed() const;
99
103 public:
104 void setFilterPassed (bool val_filterPassed);
105
106
114 public:
115 IWorker *wk () const;
116#endif
117
118
119
120 //
121 // virtual interface
122 //
123
130 protected:
131 virtual ::StatusCode initialize ();
132
137 protected:
138 virtual ::StatusCode execute (const EventContext& ctx) const;
139
145 protected:
146 virtual ::StatusCode finalize ();
147
148
149
150 //
151 // framework interface
152 //
153
154#ifdef XAOD_STANDALONE
156 public:
158
160 public:
161 ::StatusCode sysExecute (const EventContext& ctx);
162
164 public:
165 ::StatusCode sysFinalize ();
166
167
189 public:
190 asg::SgTEvent *evtStore() const;
191
197 public:
198 void setEvtStore (asg::SgTEvent *val_evtStore);
199
205 public:
206 void setFilterWorker (IFilterWorker *val_filterWorker);
207
213 public:
214 void setWk (IWorker *val_wk);
215#endif
216
217
218
219 //
220 // private interface
221 //
222
223#ifdef XAOD_STANDALONE
225 private:
226 asg::SgTEvent *m_evtStore = nullptr;
227#endif
228
229#ifdef XAOD_STANDALONE
231 private:
232 IFilterWorker *m_filterWorker = nullptr;
233#endif
234
235#ifdef XAOD_STANDALONE
237 private:
238 IWorker *m_wk = nullptr;
239#endif
240 };
241}
242
243#endif
macros for messaging and checking status codes
virtual bool filterPassed(const EventContext &ctx) const
virtual StatusCode sysExecute(const EventContext &ctx) override
virtual void setFilterPassed(bool state, const EventContext &ctx) const
An algorithm that can be simultaneously executed in multiple threads.
virtual::StatusCode initialize()
initialize this algorithm
virtual::StatusCode execute(const EventContext &ctx) const
execute this algorithm
AnaReentrantAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
constructor with parameters
virtual::StatusCode finalize()
finalize this algorithm
virtual ~AnaReentrantAlgorithm() noexcept
standard (virtual) destructor
the interface to the filter functions in the algorithm sequence
the interface for algorithms to access IWorker
Definition IWorker.h:40
Wrapper for TEvent to make it look like StoreGate.
Definition SgTEvent.h:44
This module defines the arguments passed from the BATCH driver to the BATCH worker.
::StatusCode StatusCode
StatusCode definition for legacy code.