Geant4 11.1.1
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4UserEventAction Class Reference

#include <G4UserEventAction.hh>

+ Inheritance diagram for G4UserEventAction:

Public Member Functions

 G4UserEventAction ()
 
virtual ~G4UserEventAction ()=default
 
virtual void SetEventManager (G4EventManager *value)
 
virtual void BeginOfEventAction (const G4Event *anEvent)
 
virtual void EndOfEventAction (const G4Event *anEvent)
 

Protected Attributes

G4EventManagerfpEventManager = nullptr
 

Detailed Description

Definition at line 48 of file G4UserEventAction.hh.

Constructor & Destructor Documentation

◆ G4UserEventAction()

G4UserEventAction::G4UserEventAction ( )

Definition at line 37 of file G4UserEventAction.cc.

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

◆ ~G4UserEventAction()

virtual G4UserEventAction::~G4UserEventAction ( )
virtualdefault

Member Function Documentation

◆ BeginOfEventAction()

void G4UserEventAction::BeginOfEventAction ( const G4Event anEvent)
virtual

Reimplemented in G4MultiEventAction.

Definition at line 58 of file G4UserEventAction.cc.

59{;}

◆ EndOfEventAction()

void G4UserEventAction::EndOfEventAction ( const G4Event anEvent)
virtual

Reimplemented in G4MultiEventAction.

Definition at line 61 of file G4UserEventAction.cc.

62{;}

◆ SetEventManager()

void G4UserEventAction::SetEventManager ( G4EventManager value)
virtual

Reimplemented in G4MultiEventAction.

Definition at line 53 of file G4UserEventAction.cc.

54{
55 fpEventManager = value;
56}
G4EventManager * fpEventManager

Referenced by G4EventManager::SetUserAction().

Member Data Documentation

◆ fpEventManager

G4EventManager* G4UserEventAction::fpEventManager = nullptr
protected

Definition at line 62 of file G4UserEventAction.hh.

Referenced by SetEventManager().


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