29 #define SToGS_Ascii_h 1
92 AsciiAction(G4String conffile =
"setup/SToGS_ascii_actions.conf");
112 Ascii(G4String conf =
"setup/SToGS_ascii_actions.conf", G4String which_gene =
"GPS", G4String which_gene_opt =
"G4Macros/GPSPointLike.mac"):
virtual void EndOfRunAction(const G4Run *)
virtual void BeginOfEventAction(const G4Event *)
Extract informations from Geant4 using SToGS sensitives and write hits in ascii files.
a G4 user's action manage by a single AllAction class
AsciiRun(std::ofstream &out)
A new event in the file starts/ends with the following characters.
virtual void EndOfEventAction(const G4Event *)
std::ofstream fOutputFile
current stream to output data
virtual void BeginOfRunAction(const G4Run *)
virtual G4Run * GenerateRun()
G4int fMaxEvents
max numer of event per files ... better to limit because of ascii file could be uged ! ...
G4int fRecordOption
0 [default] means keep all, 1 only events which gives at least one hit in the full detector ...
AsciiAction(G4String conffile="setup/SToGS_ascii_actions.conf")
This class just print out once a new run begins/ends with the run number and the number of events to ...
G4String fBaseName
base for all the files
std::ofstream & fOutputFile
current stream to output data
virtual void CloseFile()
Make sure ths file is closed properly.
virtual void OpenFile(G4int run_id)
Just check if there are collected hits in the collection.
virtual void RecordEvent(const G4Event *evt)
Base class that regroups in the same space all user's hooks. Convenient for sharing similar data...
G4int fPrintModulo
to print out status any fPrintModulo events
Ascii(G4String conf="setup/SToGS_ascii_actions.conf", G4String which_gene="GPS", G4String which_gene_opt="G4Macros/GPSPointLike.mac")
G4String fPathToData
directory where to output data