32#include "Randomize.hh"
34#include "G4UIdirectory.hh"
35#include "G4UIcmdWithAnInteger.hh"
36#include "G4UIcmdWithAString.hh"
37#include "G4UIcmdWithABool.hh"
45 : fRunAction (runAction)
48 fRndmDir->SetGuidance(
"Rndm status control.");
52 SetGuidance(
"set frequency to save rndm status on external files.");
54 fRndmSaveCmd->SetGuidance(
"freq > 0 saved on: beginOfRun.rndm");
55 fRndmSaveCmd->SetGuidance(
"freq = 1 saved on: endOfRun.rndm");
56 fRndmSaveCmd->SetGuidance(
"freq = 2 saved on: endOfEvent.rndm");
59 fRndmSaveCmd->AvailableForStates(G4State_PreInit,G4State_Idle);
62 fRndmReadCmd->SetGuidance(
"get rndm status from an external file.");
65 fRndmReadCmd->AvailableForStates(G4State_PreInit,G4State_Idle);
69 fSetAutoSeedCmd->SetGuidance(
" true: run seeds determined by system time");
70 fSetAutoSeedCmd->SetGuidance(
"false: use command 'random/resetEngineFrom'");
92 { G4cout <<
"\n---> rndm status restored from file: " << newValue << G4endl;
93 G4Random::restoreEngineStatus(newValue);
94 G4Random::showEngineStatus();
Definition of the F04RunActionMessenger class.
Definition of the F04RunAction class.
F04RunAction * fRunAction
~F04RunActionMessenger() override
G4UIcmdWithABool * fSetAutoSeedCmd
void SetNewValue(G4UIcommand *, G4String) override
F04RunActionMessenger(F04RunAction *)
G4UIcmdWithAnInteger * fRndmSaveCmd
G4UIcmdWithAString * fRndmReadCmd
void SetRndmFreq(G4int val)
void SetAutoSeed(const G4bool val)