The Gaudi Framework  master (37c0b60a)
AbortEventAlg.h
Go to the documentation of this file.
1 /***********************************************************************************\
2 * (c) Copyright 1998-2024 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 #ifndef ABORTEVENTALG_H_
12 #define ABORTEVENTALG_H_
13 // Include files
14 // from Gaudi
15 #include <GaudiKernel/Algorithm.h>
16 
17 class IIncidentSvc;
18 
26 class AbortEventAlg : public Algorithm {
27 public:
30 
31  StatusCode initialize() override;
32  StatusCode execute() override;
33  StatusCode finalize() override;
34 
35 private:
36  Gaudi::Property<long> m_count{ this, "AbortedEventNumber", 3, "At which event to trigger an abort" };
37 
41  long m_counter = 0;
42 };
43 
44 #endif /*ABORTEVENTALG_H_*/
AbortEventAlg::m_counter
long m_counter
Counter of events.
Definition: AbortEventAlg.h:41
Algorithm
Alias for backward compatibility.
Definition: Algorithm.h:58
Algorithm.h
AbortEventAlg::execute
StatusCode execute() override
Algorithm execution.
Definition: AbortEventAlg.cpp:48
AbortEventAlg
Definition: AbortEventAlg.h:26
StatusCode
Definition: StatusCode.h:65
AbortEventAlg::m_count
Gaudi::Property< long > m_count
Definition: AbortEventAlg.h:36
SmartIF< IIncidentSvc >
AbortEventAlg::initialize
StatusCode initialize() override
Algorithm initialization.
Definition: AbortEventAlg.cpp:32
AbortEventAlg::m_incidentSvc
SmartIF< IIncidentSvc > m_incidentSvc
Pointer to the incident service.
Definition: AbortEventAlg.h:39
AbortEventAlg::finalize
StatusCode finalize() override
Algorithm finalization.
Definition: AbortEventAlg.cpp:60
Gaudi::Algorithm::Algorithm
Algorithm(std::string name, ISvcLocator *svcloc, std::string version=PACKAGE_VERSION)
Constructor.
Definition: Algorithm.h:101
IIncidentSvc
Definition: IIncidentSvc.h:33
Gaudi::Property< long >