MARLEY (Model of Argon Reaction Low Energy Yields)  v1.2.0
A Monte Carlo event generator for tens-of-MeV neutrino interactions
Public Member Functions | List of all members
marley::RootOutputFile Class Reference
Inheritance diagram for marley::RootOutputFile:
marley::OutputFile

Public Member Functions

 RootOutputFile (const std::string &name, const std::string &format, const std::string &mode, bool force=false)
 
int_fast64_t bytes_written () override
 The number of bytes that have been written during the current MARLEY session to this file.
 
virtual void write_flux_avg_tot_xsec (double) override
 If needed (for the HEPEVT and ASCII formats), write the flux-averaged total cross section to the file. More...
 
- Public Member Functions inherited from marley::OutputFile
 OutputFile (const std::string &name, const std::string &format, const std::string &mode, bool force=false)
 
bool mode_is_resume () const
 
const std::string & name () const
 

Additional Inherited Members

- Public Types inherited from marley::OutputFile
enum class  Format { ROOT , HEPEVT , JSON , ASCII }
 
- Protected Types inherited from marley::OutputFile
enum class  Mode { OVERWRITE , APPEND , RESUME }
 
- Protected Member Functions inherited from marley::OutputFile
bool check_if_file_exists (const std::string &filename)
 Checks that a given file exists (and is readable)
 
std::unique_ptr< marley::Generatorrestore_generator (const marley::JSON &config)
 Helper function for resume() that instantiates a marley::Generator object given the previous JSON configuration object.
 
- Protected Attributes inherited from marley::OutputFile
bool force_
 
Format format_
 Format to use when writing events to the file.
 
Mode mode_
 
std::string name_
 Name of the file to receive output.
 

Member Function Documentation

◆ write_flux_avg_tot_xsec()

virtual void marley::RootOutputFile::write_flux_avg_tot_xsec ( double  avg_tot_xsec)
inlineoverridevirtual

If needed (for the HEPEVT and ASCII formats), write the flux-averaged total cross section to the file.

This function is a no-op unless we're at the beginning of the output stream.

Implements marley::OutputFile.


The documentation for this class was generated from the following files: