ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Simulation
G4Utilities
G4UserActions
src
LooperKiller.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 G4USERACTIONS_G4UA_LOOPERKILLER_H
6
#define G4USERACTIONS_G4UA_LOOPERKILLER_H
7
8
#include "GaudiKernel/ServiceHandle.h"
9
10
// Infrastructure includes
11
#include "G4UserSteppingAction.hh"
12
#include "
AthenaBaseComps/AthMessaging.h
"
13
14
class
StoreGateSvc
;
15
16
namespace
G4UA
17
{
18
22
class
LooperKiller
final :
public
G4UserSteppingAction,
public
AthMessaging
23
{
24
25
public
:
26
27
struct
Config
28
{
29
int
MaxSteps
=1000000;
30
int
PrintSteps
=100;
31
int
VerboseLevel
=1;
32
bool
AbortEvent
=
true
;
33
bool
SetError
=
false
;
34
bool
BSM_Only
=
false
;
35
};
36
37
struct
Report
38
{
39
long
killed_tracks
=0;
40
void
merge
(
const
Report
& rep){
41
killed_tracks
+=rep.killed_tracks;
42
}
43
};
44
45
LooperKiller
(
const
Config
& config);
46
47
virtual
void
UserSteppingAction
(
const
G4Step*)
override
;
49
const
Report
&
getReport
()
const
50
{
return
m_report
; }
51
52
private
:
53
54
typedef
ServiceHandle<StoreGateSvc>
StoreGateSvc_t
;
56
StoreGateSvc_t
m_evtStore
;
58
StoreGateSvc_t
m_detStore
;
59
61
Config
m_config
;
62
Report
m_report
;
63
int
m_count_steps
;
64
65
};
// class LooperKiller
66
67
}
68
69
#endif
AthMessaging.h
AthMessaging::AthMessaging
AthMessaging(IMessageSvc *msgSvc, const std::string &name)
Constructor.
Definition
AthMessaging.cxx:13
G4UA::LooperKiller::m_config
Config m_config
My configuration options.
Definition
LooperKiller.h:61
G4UA::LooperKiller::m_report
Report m_report
Definition
LooperKiller.h:62
G4UA::LooperKiller::getReport
const Report & getReport() const
Retrieve results.
Definition
LooperKiller.h:49
G4UA::LooperKiller::m_count_steps
int m_count_steps
Definition
LooperKiller.h:63
G4UA::LooperKiller::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default).
Definition
LooperKiller.h:56
G4UA::LooperKiller::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default).
Definition
LooperKiller.h:58
G4UA::LooperKiller::LooperKiller
LooperKiller(const Config &config)
Definition
LooperKiller.cxx:31
G4UA::LooperKiller::UserSteppingAction
virtual void UserSteppingAction(const G4Step *) override
Definition
LooperKiller.cxx:41
G4UA::LooperKiller::StoreGateSvc_t
ServiceHandle< StoreGateSvc > StoreGateSvc_t
Definition
LooperKiller.h:54
ServiceHandle
Definition
ClusterMakerTool.h:36
StoreGateSvc
The Athena Transient Store API.
Definition
StoreGateSvc.h:120
G4UA
for nSW
Definition
CalibrationDefaultProcessing.h:19
Config
Definition
dumpNPs.cxx:47
G4UA::LooperKiller::Config
Definition
LooperKiller.h:28
G4UA::LooperKiller::Config::PrintSteps
int PrintSteps
Definition
LooperKiller.h:30
G4UA::LooperKiller::Config::VerboseLevel
int VerboseLevel
Definition
LooperKiller.h:31
G4UA::LooperKiller::Config::BSM_Only
bool BSM_Only
Definition
LooperKiller.h:34
G4UA::LooperKiller::Config::AbortEvent
bool AbortEvent
Definition
LooperKiller.h:32
G4UA::LooperKiller::Config::SetError
bool SetError
Definition
LooperKiller.h:33
G4UA::LooperKiller::Config::MaxSteps
int MaxSteps
Definition
LooperKiller.h:29
G4UA::LooperKiller::Report
Definition
LooperKiller.h:38
G4UA::LooperKiller::Report::merge
void merge(const Report &rep)
Definition
LooperKiller.h:40
G4UA::LooperKiller::Report::killed_tracks
long killed_tracks
Definition
LooperKiller.h:39
Generated on
for ATLAS Offline Software by
1.17.0