k4SimGeant4
Loading...
Searching...
No Matches
ParticleHistoryAction.h
Go to the documentation of this file.
1#ifndef SIMG4FULL_PARTICLEHISTORYACTION_H
2#define SIMG4FULL_PARTICLEHISTORYACTION_H
3
4#include "G4UserTrackingAction.hh"
5
16namespace sim {
17class ParticleHistoryAction : public G4UserTrackingAction {
18public:
19 ParticleHistoryAction(double energyCut);
20 virtual ~ParticleHistoryAction() = default;
21
23 void PreUserTrackingAction(const G4Track* aTrack);
25 void PostUserTrackingAction(const G4Track* aTrack);
26
31 bool selectSecondary(const G4Track& aTrack, double aEnergyCut);
32private:
35};
36}
37
38#endif /* SIMG4FULL_PARTICLEHISTORYACTION_H */
Definition ParticleHistoryAction.h:17
void PreUserTrackingAction(const G4Track *aTrack)
empty action - particles are only saved at the end of track
Definition ParticleHistoryAction.cpp:12
double m_energyCut
energy threshold for secondaries to be saved
Definition ParticleHistoryAction.h:34
virtual ~ParticleHistoryAction()=default
bool selectSecondary(const G4Track &aTrack, double aEnergyCut)
Simple filter for particles to be saved, based on their energy.
Definition ParticleHistoryAction.cpp:24
ParticleHistoryAction(double energyCut)
Definition ParticleHistoryAction.cpp:10
void PostUserTrackingAction(const G4Track *aTrack)
particles are saved here, after geant4 is done simulating the track
Definition ParticleHistoryAction.cpp:22
Conversion between units.
Definition ConstantField.h:14