26 #include "CLHEP/Random/EngineFactory.h"
32 using namespace DD4hep::Simulation;
70 unsigned int eventID = evt->GetEventID();
74 "At beginEvent: eventID=%u, runID=%u initialSeed=%u, newSeed=%u" ,
virtual ~Geant4EventSeed()
Default destructor.
void begin(const G4Run *)
begin-of-run callback
#define DECLARE_GEANT4ACTION(name)
Plugin defintion to create Geant4Action objects.
static void decrement(T *)
Decrement count according to type information.
Concrete basic implementation of the Geant4 run action base class.
PrintLevel printLevel()
Access the current printer level.
void callAtBegin(Q *p, void(T::*f)(const G4Event *))
Register begin-of-event callback.
void beginEvent(const G4Event *)
begin-of-event callback
static Geant4Random * instance(bool throw_exception=true)
Access the main Geant4 random generator instance. Must be created before used!
unsigned int m_initialSeed
void callAtBegin(Q *p, void(T::*f)(const G4Run *))
Register begin-of-run callback. Types Q and T must be polymorph!
virtual void setSeed(long seed)
Should initialise the status of the algorithm according to seed.
unsigned int hash(unsigned int initialSeed, unsigned int eventNumber, unsigned int runNumber)
calculate hash from initialSeed, eventID and runID
CLHEP::HepRandomEngine * engine()
CLHEP random number engine (valid after initialization only)
static void increment(T *)
Increment count according to type information.
Geant4EventSeed(Geant4Context *, const std::string &)
Standard constructor with initializing arguments.
virtual void showStatus() const
Should dump the current engine status on the screen.
Geant4RunActionSequence & runAction() const
Access to the main run action sequence from the kernel object.
Generic context to extend user, run and event information.
Mini interface to THE random generator of the application.
Geant4EventActionSequence & eventAction() const
Access to the main event action sequence from the kernel object.
int printout(PrintLevel severity, const char *src, const char *fmt,...)
Calls the display action with a given severity level.