Celeritas
0.5.0-56+6b053cd
|
HepMC3 reader class for sharing across threads. More...
#include <HepMC3PrimaryGenerator.hh>
Public Member Functions | |
HepMC3PrimaryGenerator (std::string const &filename) | |
Construct with a path to a HepMC3-compatible input file. | |
CELER_DELETE_COPY_MOVE (HepMC3PrimaryGenerator) | |
void | GeneratePrimaryVertex (G4Event *g4_event) final |
Add primaries to Geant4 event. More... | |
int | NumEvents () |
Get total number of events. | |
HepMC3 reader class for sharing across threads.
This singleton is shared among threads so that events can be correctly split up between them, being constructed the first time instance()
is invoked. As this is a derived G4VPrimaryGenerator
class, the HepMC3PrimaryGenerator must be used by a concrete implementation of the G4VUserPrimaryGeneratorAction
class:
|
inlinefinal |
Add primaries to Geant4 event.
Add HepMC3 primaries to a Geant4 event.
This function should be called by G4VUserPrimaryGeneratorAction::GeneratePrimaries
.