SLIC  6.1.1
Simulation for the Linear Collider (SLIC) - Geant4 simulation application
Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
EventAction Class Reference

Implementation of G4UserEventAction. More...

#include <EventAction.hh>

Inheritance diagram for EventAction:
Module PluginManagerAccessor

Public Member Functions

 EventAction ()
 
virtual ~EventAction ()
 
void BeginOfEventAction (const G4Event *anEvent)
 
void enableEventTimer (bool et=true)
 
virtual void EndOfEventAction (const G4Event *anEvent)
 
void startEventTimer ()
 
void stopEventTimer ()
 
- Public Member Functions inherited from Module
virtual ~Module ()
 
virtual void beginEvent (const G4Event *)
 
virtual void beginRun (const G4Run *)
 
virtual void cleanup ()
 
bool deleteOnExit ()
 
virtual void endEvent (const G4Event *)
 
virtual void endRun (const G4Run *)
 
const std::string & getName () const
 
ModuleStatus getStatus () const
 
virtual void initialize ()
 
LogStream & log ()
 
virtual void postTracking (const G4Track *)
 
virtual void preTracking (const G4Track *)
 
virtual void reset ()
 
virtual void stepping (const G4Step *)
 
- Public Member Functions inherited from PluginManagerAccessor
PluginManager * getPluginManager ()
 
void setPluginManager (PluginManager *pluginManager)
 

Static Public Member Functions

static EventAction * getEventAction ()
 

Private Attributes

bool m_enableEventTimer
 
G4Timer m_eventTimer
 
G4UImessenger * m_messenger
 

Additional Inherited Members

- Public Types inherited from Module
enum  ModuleStatus { eOkay = 0 , eNotInitialized = 1 , eBadState = 2 , eFatalError = 3 }
 
- Public Attributes inherited from Module
bool m_deleteOnExit
 
LogStream * m_log
 
std::string m_name
 
ModuleStatus m_status
 
- Protected Member Functions inherited from Module
 Module (const std::string &name, bool deleteOnExit=true, bool autoRegister=true)
 
- Protected Attributes inherited from PluginManagerAccessor
PluginManager * m_pluginManager
 

Detailed Description

Implementation of G4UserEventAction.

Note
Calls actions of TrajectoryManager and LcioManager.

Definition at line 25 of file EventAction.hh.

Constructor & Destructor Documentation

◆ EventAction()

Class constructor.

Definition at line 22 of file EventAction.cc.

References EventAction::m_messenger.

◆ ~EventAction()

~EventAction ( )
virtual

Class destructor.

Definition at line 27 of file EventAction.cc.

Member Function Documentation

◆ BeginOfEventAction()

void BeginOfEventAction ( const G4Event *  anEvent)

Callback for the beginning of a Geant4 event.

Parameters
[in]anEventThe Geant4 event.

Definition at line 30 of file EventAction.cc.

References PluginManager::beginEvent(), and PluginManagerAccessor::m_pluginManager.

◆ enableEventTimer()

void enableEventTimer ( bool  et = true)

Enable or disable the event processing timer.

Parameters
[in]etThe event timer setting; true to turn on.

Definition at line 93 of file EventAction.cc.

References EventAction::m_enableEventTimer.

Referenced by EventMessenger::SetNewValue().

◆ EndOfEventAction()

void EndOfEventAction ( const G4Event *  anEvent)
virtual

◆ getEventAction()

EventAction * getEventAction ( )
static

Get the singleton instance of this class.

Returns
The EventAction object.

Definition at line 70 of file EventAction.cc.

Referenced by EventSourceManager::beginEvent(), and EventMessenger::SetNewValue().

◆ startEventTimer()

void startEventTimer ( )

Start the event timer.

Definition at line 84 of file EventAction.cc.

References LOG::done, Module::log(), EventAction::m_enableEventTimer, EventAction::m_eventTimer, and LOG::verbose.

Referenced by EventSourceManager::beginEvent().

◆ stopEventTimer()

void stopEventTimer ( )

Stop the event timer.

Definition at line 75 of file EventAction.cc.

References LOG::done, Module::log(), EventAction::m_enableEventTimer, EventAction::m_eventTimer, and LOG::okay.

Referenced by EventAction::EndOfEventAction().

Member Data Documentation

◆ m_enableEventTimer

bool m_enableEventTimer
private

Print the end of event message.

Parameters
[in]anEventThe Geant4 event.

Definition at line 85 of file EventAction.hh.

Referenced by EventAction::enableEventTimer(), EventAction::startEventTimer(), and EventAction::stopEventTimer().

◆ m_eventTimer

G4Timer m_eventTimer
mutableprivate

Definition at line 86 of file EventAction.hh.

Referenced by EventAction::startEventTimer(), and EventAction::stopEventTimer().

◆ m_messenger

G4UImessenger* m_messenger
private

Definition at line 88 of file EventAction.hh.

Referenced by EventAction::EventAction().


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