allpix::PrimariesReader
Interface class to read primary particles from input data in different file formats.
#include <PrimariesReader.hpp>
Inherited by allpix::PrimariesReaderGenie, allpix::PrimariesReaderHepMC
Public Classes
Name | |
---|---|
class | Particle Particle class to hold information for primary particles before dispatching them to Geant4. |
Public Types
Name | |
---|---|
enum class | FileModel { GENIE, HEPMC, HEPMC2, HEPMCROOT, HEPMCTTREE} Different implemented file models. |
Public Functions
Name | |
---|---|
PrimariesReader() =default | |
virtual | ~PrimariesReader() =default |
virtual std::vector< Particle > | getParticles() =0 |
uint64_t | eventNum() const |
Friends
Name | |
---|---|
class | DepositionGeneratorModule |
Public Types Documentation
enum FileModel
Enumerator | Value | Description |
---|---|---|
GENIE | Genie generator ROOT files. | |
HEPMC | HepMC data files from generators such as Pythia. | |
HEPMC2 | HepMC2 data files, outdated format. | |
HEPMCROOT | HepMC ROOTIO file format. | |
HEPMCTTREE | HepMC ROOTIO TTree file format. |
Different implemented file models.
Public Functions Documentation
function PrimariesReader
PrimariesReader() =default
Default constructor and destructor
function ~PrimariesReader
virtual ~PrimariesReader() =default
function getParticles
virtual std::vector< Particle > getParticles() =0
Return: Vector of primary particles
Reimplemented by: allpix::PrimariesReaderGenie::getParticles, allpix::PrimariesReaderHepMC::getParticles
Purely virtual method to obtain a vector of primary particles for the current event. This methods needs to be implemented by derived classes which implement a specific file format. This method normally needs to be called sequentially and is not thread-safe.
function eventNum
inline uint64_t eventNum() const
Return: Event number
Get the event number of the currently processed event. This allows to cross-check with potentially available event ID information from the input data file.
Friends
friend DepositionGeneratorModule
friend class DepositionGeneratorModule(
DepositionGeneratorModule
);
Updated on 2024-12-13 at 08:31:36 +0000