17#ifndef _RMG_GRABMAYR_GC_READER_HH_
18#define _RMG_GRABMAYR_GC_READER_HH_
27#include "G4GenericMessenger.hh"
43 std::vector<G4int>
eg;
54class RMGGrabmayrGCReader {
59 ~RMGGrabmayrGCReader();
75 static G4ThreadLocal RMGGrabmayrGCReader* instance;
76 RMGGrabmayrGCReader();
79 std::map<std::pair<G4int, G4int>, std::unique_ptr<std::ifstream>> fCascadeFiles;
80 std::unique_ptr<G4GenericMessenger> fGenericMessenger;
81 G4int fGammaCascadeRandomStartLocation = 0;
83 void SetGammaCascadeFile(G4int z, G4int a,
G4String file_name);
84 void SetGammaCascadeRandomStartLocation(
int answer);
85 void SetStartLocation(std::ifstream& file)
const;
87 void RandomizeFiles();
88 void DefineCommands();
94 GCMessenger(RMGGrabmayrGCReader* reader);
101 RMGGrabmayrGCReader* fReader;
104 void GammaFileCmd(
const std::string& parameters);
107 std::unique_ptr<GCMessenger> fUIMessenger;
static RMGGrabmayrGCReader * GetInstance()
Thread-local singleton accessor.
Definition RMGGrabmayrGCReader.cc:28
void CloseFiles()
Close all open cascade files held by this thread.
Definition RMGGrabmayrGCReader.cc:37
GammaCascadeLine GetNextEntry(G4int z, G4int a)
Read and return the next cascade entry for the (Z, A) isotope.
Definition RMGGrabmayrGCReader.cc:52
G4bool IsApplicable(G4int z, G4int a)
Whether a cascade file has been registered for the (Z, A) isotope.
Definition RMGGrabmayrGCReader.cc:45
One pre-computed neutron-capture gamma cascade.
Definition RMGGrabmayrGCReader.hh:38
G4int m
Cascade multiplicity (number of eg entries).
Definition RMGGrabmayrGCReader.hh:41
std::vector< G4int > eg
Photon energies of the cascade [keV].
Definition RMGGrabmayrGCReader.hh:43
G4int en
Neutron kinetic energy bin [keV].
Definition RMGGrabmayrGCReader.hh:39
G4int em
Missing energy not carried by the listed photons [keV].
Definition RMGGrabmayrGCReader.hh:42
G4int ex
Capture-state excitation energy [keV].
Definition RMGGrabmayrGCReader.hh:40