ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
LArCalorimeter
LArG4
LArG4Code
LArG4Code
SimpleSDTool.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef LARG4CODE_SIMPLESDTOOL_H
6
#define LARG4CODE_SIMPLESDTOOL_H
7
14
15
// System includes
16
#include <string>
17
#include <vector>
18
19
// G4Atlas includes
20
#include "
G4AtlasTools/SensitiveDetectorBase.h
"
21
22
#include "
HitManagement/HitCollectionMap.h
"
23
24
// Local includes
25
#include "
LArG4SimpleSD.h
"
26
27
// External includes
28
#include "CLHEP/Units/SystemOfUnits.h"
29
30
// Forward declarations
31
class
ILArCalculatorSvc
;
32
class
LArEM_ID
;
33
class
LArFCAL_ID
;
34
class
LArHEC_ID
;
35
class
LArG4SimpleSD
;
36
37
namespace
LArG4
38
{
39
49
class
SimpleSDTool
:
public
SensitiveDetectorBase
50
{
51
52
public
:
53
55
SimpleSDTool
(
const
std::string&
type
,
const
std::string& name,
56
const
IInterface* parent);
57
59
StatusCode
initialize
() override final;
60
62
StatusCode
initializeSD
() override final;
63
65
StatusCode
SetupEvent
(
HitCollectionMap
&) override final;
66
68
StatusCode
Gather
(
HitCollectionMap
&) override final;
69
70
protected
:
71
73
virtual StatusCode
initializeCalculators
() {
return
StatusCode::SUCCESS; }
74
76
LArG4SimpleSD
*
77
makeOneSD
(
const
std::string& name,
ILArCalculatorSvc
* calc,
78
const
std::vector<std::string>& volumes)
const
;
79
81
bool
useFrozenShowers
()
const
{
return
m_useFrozenShowers
; }
82
84
virtual
std::string
hitCollectionName
()
const
;
85
86
protected
:
87
90
92
Gaudi::Property<std::string>
m_timeBinType
{
this
,
"TimeBinType"
,
"Default"
};
94
Gaudi::Property<float>
m_timeBinWidth
{
this
,
"TimeBinWidth"
, 2.5*CLHEP::ns};
96
Gaudi::Property<G4bool>
m_useFrozenShowers
{
this
,
"UseFrozenShowers"
,
false
};
97
99
102
const
LArEM_ID
*
m_larEmID
{
nullptr
};
103
const
LArFCAL_ID
*
m_larFcalID
{
nullptr
};
104
const
LArHEC_ID
*
m_larHecID
{
nullptr
};
106
107
};
// class SimpleSDTool
108
109
}
// namespace LArG4
110
111
#endif
HitCollectionMap.h
LArG4SimpleSD.h
SensitiveDetectorBase.h
HitCollectionMap
Small wrapper around hit collection map to facilitate accessing the hit collection.
Definition
HitCollectionMap.h:23
ILArCalculatorSvc
Definition
ILArCalculatorSvc.h:25
LArEM_ID
Helper class for LArEM offline identifiers.
Definition
LArEM_ID.h:111
LArFCAL_ID
Helper class for LArFCAL offline identifiers.
Definition
LArFCAL_ID.h:49
LArG4SimpleSD
Common sensitive detector class for LAr systems.
Definition
LArG4SimpleSD.h:38
LArG4::SimpleSDTool::m_larHecID
const LArHEC_ID * m_larHecID
Definition
SimpleSDTool.h:104
LArG4::SimpleSDTool::SimpleSDTool
SimpleSDTool(const std::string &type, const std::string &name, const IInterface *parent)
Constructor.
LArG4::SimpleSDTool::initializeSD
StatusCode initializeSD() override final
Create and register all SDs for the current thread.
LArG4::SimpleSDTool::initializeCalculators
virtual StatusCode initializeCalculators()
Initialize Calculator Services.
Definition
SimpleSDTool.h:73
LArG4::SimpleSDTool::makeOneSD
LArG4SimpleSD * makeOneSD(const std::string &name, ILArCalculatorSvc *calc, const std::vector< std::string > &volumes) const
Helper method to create one SD.
LArG4::SimpleSDTool::m_timeBinWidth
Gaudi::Property< float > m_timeBinWidth
What time bin width for regular hits?
Definition
SimpleSDTool.h:94
LArG4::SimpleSDTool::Gather
StatusCode Gather(HitCollectionMap &) override final
Finalize and record event-owned hit collections.
LArG4::SimpleSDTool::m_larEmID
const LArEM_ID * m_larEmID
Definition
SimpleSDTool.h:102
LArG4::SimpleSDTool::m_larFcalID
const LArFCAL_ID * m_larFcalID
Definition
SimpleSDTool.h:103
LArG4::SimpleSDTool::m_timeBinType
Gaudi::Property< std::string > m_timeBinType
What time binning type for regular hits?
Definition
SimpleSDTool.h:92
LArG4::SimpleSDTool::useFrozenShowers
bool useFrozenShowers() const
Are we handling frozen shower fast sim?
Definition
SimpleSDTool.h:81
LArG4::SimpleSDTool::SetupEvent
StatusCode SetupEvent(HitCollectionMap &) override final
Create event-owned hit collections.
LArG4::SimpleSDTool::m_useFrozenShowers
Gaudi::Property< G4bool > m_useFrozenShowers
Is there going to be a fast simulation coming into this SD?
Definition
SimpleSDTool.h:96
LArG4::SimpleSDTool::initialize
StatusCode initialize() override final
Initialize the tool.
LArG4::SimpleSDTool::hitCollectionName
virtual std::string hitCollectionName() const
Collection receiving the hits for this tool.
LArHEC_ID
Helper class for LArHEC offline identifiers.
Definition
LArHEC_ID.h:76
SensitiveDetectorBase::SensitiveDetectorBase
SensitiveDetectorBase(const std::string &type, const std::string &name, const IInterface *parent)
Standard constructor.
Definition
SensitiveDetectorBase.cxx:17
LArG4
Definition
LArWheelCalculatorEnums.h:8
type
protected
#define protected
Definition
testRead.cxx:26
Generated on
for ATLAS Offline Software by
1.17.0