Geant4-11
Public Member Functions | Protected Attributes
G4UserTrackingAction Class Reference

#include <G4UserTrackingAction.hh>

Inheritance diagram for G4UserTrackingAction:
CB_G4UserTrackingAction G4AdjointTrackingAction G4MultiTrackingAction G4RTTrackingAction

Public Member Functions

 G4UserTrackingAction ()
 
virtual void PostUserTrackingAction (const G4Track *)
 
virtual void PreUserTrackingAction (const G4Track *)
 
virtual void SetTrackingManagerPointer (G4TrackingManager *pValue)
 
virtual ~G4UserTrackingAction ()
 

Protected Attributes

G4TrackingManagerfpTrackingManager = nullptr
 

Detailed Description

Definition at line 44 of file G4UserTrackingAction.hh.

Constructor & Destructor Documentation

◆ G4UserTrackingAction()

G4UserTrackingAction::G4UserTrackingAction ( )

Definition at line 39 of file G4UserTrackingAction.cc.

41{
42 if(!(G4ParticleTable::GetParticleTable()->GetReadiness()))
43 {
44 G4String msg;
45 msg = " You are instantiating G4UserTrackingAction BEFORE your\n";
46 msg += "G4VUserPhysicsList is instantiated and assigned to G4RunManager.\n";
47 msg += " Such an instantiation is prohibited. To fix this problem,\n";
48 msg += "please make sure that your main() instantiates G4VUserPhysicsList AND\n";
49 msg += "set it to G4RunManager before instantiating other user action classes\n";
50 msg += "such as G4UserTrackingAction.";
51 G4Exception("G4UserTrackingAction::G4UserTrackingAction()",
52 "Tracking0001", FatalException, msg);
53 }
54}
@ FatalException
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
Definition: G4Exception.cc:35
static G4ParticleTable * GetParticleTable()

References FatalException, G4Exception(), and G4ParticleTable::GetParticleTable().

◆ ~G4UserTrackingAction()

G4UserTrackingAction::~G4UserTrackingAction ( )
virtual

Definition at line 57 of file G4UserTrackingAction.cc.

59{
60}

Member Function Documentation

◆ PostUserTrackingAction()

virtual void G4UserTrackingAction::PostUserTrackingAction ( const G4Track )
inlinevirtual

◆ PreUserTrackingAction()

virtual void G4UserTrackingAction::PreUserTrackingAction ( const G4Track )
inlinevirtual

◆ SetTrackingManagerPointer()

void G4UserTrackingAction::SetTrackingManagerPointer ( G4TrackingManager pValue)
virtual

Reimplemented in G4MultiTrackingAction.

Definition at line 63 of file G4UserTrackingAction.cc.

65{
66 fpTrackingManager = pValue;
67}
G4TrackingManager * fpTrackingManager

References fpTrackingManager.

Referenced by G4TrackingManager::SetUserAction().

Field Documentation

◆ fpTrackingManager

G4TrackingManager* G4UserTrackingAction::fpTrackingManager = nullptr
protected

The documentation for this class was generated from the following files: