The Gaudi Framework
master (6507eef1)
Toggle main menu visibility
Loading...
Searching...
No Matches
ReadAlg.h
Go to the documentation of this file.
1
/***********************************************************************************\
2
* (c) Copyright 1998-2025 CERN for the benefit of the LHCb and ATLAS collaborations *
3
* *
4
* This software is distributed under the terms of the Apache version 2 licence, *
5
* copied verbatim in the file "LICENSE". *
6
* *
7
* In applying this licence, CERN does not waive the privileges and immunities *
8
* granted to it by virtue of its status as an Intergovernmental Organization *
9
* or submit itself to any jurisdiction. *
10
\***********************************************************************************/
11
#pragma once
12
13
// Framework include files
14
#include <
GaudiKernel/Algorithm.h
>
// Required for inheritance
15
#include <
GaudiKernel/IIncidentListener.h
>
// Required for inheritance
16
17
// Forward declarations
18
#include <mutex>
19
20
class
IIncidentSvc
;
21
28
29
class
ReadAlg
:
public
Algorithm
,
virtual
public
IIncidentListener
{
31
SmartIF<IDataProviderSvc>
m_recordSvc
;
33
SmartIF<IIncidentSvc>
m_incidentSvc
;
34
Gaudi::Property<std::string>
m_incidentName
{
this
,
"IncidentName"
,
""
,
"incident name of records service"
};
36
std::mutex
m_mutex
;
37
38
public
:
40
using
Algorithm::Algorithm
;
42
StatusCode
initialize
()
override
;
44
StatusCode
finalize
()
override
;
46
StatusCode
execute
()
override
;
48
void
handle
(
const
Incident
& incident )
override
;
49
};
Algorithm.h
IIncidentListener.h
Gaudi::Algorithm::Algorithm
Algorithm(std::string name, ISvcLocator *svcloc, std::string version=PACKAGE_VERSION)
Constructor.
Definition
Algorithm.h:98
Gaudi::Property
Implementation of property with value of concrete type.
Definition
Property.h:35
IIncidentListener
The interface implemented by any class wanting to listen to Incidents.
Definition
IIncidentListener.h:23
IIncidentSvc
The interface implemented by the IncidentSvc service.
Definition
IIncidentSvc.h:30
Incident
Base class for all Incidents (computing events).
Definition
Incident.h:24
ReadAlg
ReadAlg class for the RootIOExample.
Definition
ReadAlg.h:29
ReadAlg::execute
StatusCode execute() override
Event callback.
Definition
ReadAlg.cpp:121
ReadAlg::m_incidentSvc
SmartIF< IIncidentSvc > m_incidentSvc
Reference to incident service.
Definition
ReadAlg.h:33
ReadAlg::m_recordSvc
SmartIF< IDataProviderSvc > m_recordSvc
Reference to run records data service.
Definition
ReadAlg.h:31
ReadAlg::m_mutex
std::mutex m_mutex
protection for thread safe usage
Definition
ReadAlg.h:36
ReadAlg::m_incidentName
Gaudi::Property< std::string > m_incidentName
Definition
ReadAlg.h:34
ReadAlg::finalize
StatusCode finalize() override
Finalize.
Definition
ReadAlg.cpp:87
ReadAlg::handle
void handle(const Incident &incident) override
IIncidentListener override: Inform that a new incident has occured.
Definition
ReadAlg.cpp:97
ReadAlg::initialize
StatusCode initialize() override
Initialize.
Definition
ReadAlg.cpp:50
SmartIF
Small smart pointer class with automatic reference counting for IInterface.
Definition
SmartIF.h:28
StatusCode
This class is used for returning status codes from appropriate routines.
Definition
StatusCode.h:64
GaudiTestSuite
src
IO
ReadAlg.h
Generated on
for The Gaudi Framework by
1.17.0