ATLAS Offline Software
Loading...
Searching...
No Matches
Simulation
G4Utilities
G4Ancillary
G4AncillarySimEvent
src
SimpleScintillatorHit.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3
*/
4
6
// SimpleScintillatorHit.h
7
// Implementation file for class SimpleScintillatorHit
8
//
9
// Author Andrea Di Simone. Based on ScintillatorHit by homas Kittelmann <kittel@nbi.dk>
11
#include "
G4AncillarySimEvent/SimpleScintillatorHit.h
"
12
13
// Default constructor needed by athenaroot
14
SimpleScintillatorHit::SimpleScintillatorHit
() :
15
m_particleEncoding
(0),
16
m_kineticEnergy
(0),
17
m_energyDeposit
(0),
18
m_position
(0),
19
m_globalTime
(0),
20
m_copyNo
(0),
21
m_partLink
() {}
22
23
SimpleScintillatorHit::~SimpleScintillatorHit
() {}
24
25
// Constructor
26
SimpleScintillatorHit::SimpleScintillatorHit
(
const
int
particleEncoding,
27
const
float
kineticEnergy,
28
const
float
energyDeposit,
29
const
CLHEP::Hep3Vector& position,
30
const
float
globalTime,
31
const
int
copyNo,
32
const
int
track) :
33
m_particleEncoding
(particleEncoding),
34
m_kineticEnergy
(kineticEnergy),
35
m_energyDeposit
(energyDeposit),
36
m_position
(position),
37
m_globalTime
(globalTime),
38
m_copyNo
(copyNo),
39
m_partLink
(track, 0,
HepMcParticleLink
::IS_POSITION,
HepMcParticleLink
::IS_BARCODE)
// FIXME barcode-based syntax
40
{}
41
42
int
SimpleScintillatorHit::truthBarcode
()
const
{
43
return
HepMC::barcode
(
m_partLink
);
// FIXME barcode-based
44
}
45
46
int
SimpleScintillatorHit::truthID
()
const
47
{
48
return
m_partLink
.id();
49
}
SimpleScintillatorHit.h
HepMcParticleLink
a link optimized in size for a GenParticle in a McEventCollection
Definition
HepMcParticleLink.h:72
SimpleScintillatorHit::m_copyNo
int m_copyNo
Definition
SimpleScintillatorHit.h:57
SimpleScintillatorHit::truthID
int truthID() const
Definition
SimpleScintillatorHit.cxx:46
SimpleScintillatorHit::m_particleEncoding
int m_particleEncoding
Definition
SimpleScintillatorHit.h:52
SimpleScintillatorHit::m_kineticEnergy
float m_kineticEnergy
Definition
SimpleScintillatorHit.h:53
SimpleScintillatorHit::~SimpleScintillatorHit
virtual ~SimpleScintillatorHit()
Definition
SimpleScintillatorHit.cxx:23
SimpleScintillatorHit::m_partLink
HepMcParticleLink m_partLink
Definition
SimpleScintillatorHit.h:58
SimpleScintillatorHit::m_position
CLHEP::Hep3Vector m_position
Definition
SimpleScintillatorHit.h:55
SimpleScintillatorHit::m_globalTime
float m_globalTime
Definition
SimpleScintillatorHit.h:56
SimpleScintillatorHit::SimpleScintillatorHit
SimpleScintillatorHit()
Definition
SimpleScintillatorHit.cxx:14
SimpleScintillatorHit::truthBarcode
int truthBarcode() const
Definition
SimpleScintillatorHit.cxx:42
SimpleScintillatorHit::m_energyDeposit
float m_energyDeposit
Definition
SimpleScintillatorHit.h:54
HepMC::barcode
int barcode(const T *p)
Definition
Barcode.h:16
Generated on
for ATLAS Offline Software by
1.14.0