LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
ArtG4TrackingAction.hh
Go to the documentation of this file.
1 // ArtG4TrackingAction.hh provides declarations for the built-in tracking action
2 // for the Art G4 simulation. In its two main methods, PreUserTrackingAction
3 // and PostUserTrackingAction, it gets the collection of all action objects
4 // registered for the simulation job and loops over them, calling their
5 // respective methods (conveniently called Pre/PostUserTrackingAction).
6 
7 // Authors: Tasha Arvanitis, Adam Lyon
8 // Date: July 2012
9 
10 #ifndef artg4tk_geantInit_ArtG4TrackingAction_hh
11 #define artg4tk_geantInit_ArtG4TrackingAction_hh
12 
13 // G4 includes
14 #include "Geant4/G4UserTrackingAction.hh"
15 
16 namespace artg4tk {
17  class ActionHolderService;
18 
19  class ArtG4TrackingAction : public G4UserTrackingAction {
20  public:
21  explicit ArtG4TrackingAction(ActionHolderService* actionHolder);
22 
23  private:
24  // Called immediately after the creation of a track and before simulating
25  // it.
26  void PreUserTrackingAction(const G4Track* currentTrack) override;
27 
28  // Called after stopping a track
29  void PostUserTrackingAction(const G4Track* currentTrack) override;
30 
32  };
33 
34 }
35 
36 #endif /* artg4tk_geantInit_ArtG4TrackingAction_hh */
void PostUserTrackingAction(const G4Track *currentTrack) override
ActionHolderService * actionHolder_
void PreUserTrackingAction(const G4Track *currentTrack) override
ArtG4TrackingAction(ActionHolderService *actionHolder)