Stepping action class.
More...
#include <Doxymodules_basic.h>
Stepping action class.
In UserSteppingAction() there are collected the energy deposit and track lengths of charged particles in Absober and Gap layers and updated in RunData object.
Definition at line 144 of file Doxymodules_basic.h.
◆ SteppingAction()
Definition at line 44 of file SteppingAction.cc.
46{
47}
const B4::DetectorConstruction * fDetConstruction
◆ ~SteppingAction()
B4b::SteppingAction::~SteppingAction |
( |
| ) |
|
|
overridedefault |
◆ UserSteppingAction()
void B4b::SteppingAction::UserSteppingAction |
( |
const G4Step * |
step | ) |
|
|
override |
Definition at line 51 of file SteppingAction.cc.
52{
53
54
55
56 auto volume = step->GetPreStepPoint()->GetTouchableHandle()->GetVolume();
57
58
59 auto edep = step->GetTotalEnergyDeposit();
60
61
62 G4double stepLength = 0.;
63 if ( step->GetTrack()->GetDefinition()->GetPDGCharge() != 0. ) {
64 stepLength = step->GetStepLength();
65 }
66
67 auto runData = static_cast<RunData*>
68 (G4RunManager::GetRunManager()->GetNonConstCurrentRun());
69
71 runData->Add(
kAbs, edep, stepLength);
72 }
73
75 runData->Add(
kGap, edep, stepLength);
76 }
77}
const G4VPhysicalVolume * GetAbsorberPV() const
const G4VPhysicalVolume * GetGapPV() const
◆ fDetConstruction
The documentation for this class was generated from the following files: