![]() |
HepMC Reference DocumentationHepMC |
#include <IO_ExtendedAscii.h>
Inheritance diagram for HepMC::IO_ExtendedAscii:
Public Member Functions | |
IO_ExtendedAscii (const char *filename="IO_ExtendedAscii.dat", std::ios::openmode mode=std::ios::out) | |
constructor requiring a file name and std::ios mode | |
virtual | ~IO_ExtendedAscii () |
void | write_event (const GenEvent *evt) |
write this event | |
bool | fill_next_event (GenEvent *evt) |
get the next event | |
void | write_particle_data_table (const ParticleDataTable *) |
write this ParticleDataTable | |
bool | fill_particle_data_table (ParticleDataTable *) |
fill this ParticleDataTable | |
void | write_comment (const std::string comment) |
int | rdstate () const |
check the state of the IO stream | |
void | clear () |
clear the IO stream | |
void | print (std::ostream &ostr=std::cout) const |
write to ostr | |
Protected Member Functions | |
void | write_vertex (GenVertex *) |
write vertex information | |
void | write_beam_particles (std::pair< HepMC::GenParticle *, HepMC::GenParticle * >) |
write beam particle information | |
void | write_heavy_ion (HeavyIon *) |
write heavy ion information | |
void | write_pdf_info (PdfInfo *) |
write PDF information | |
void | write_particle (GenParticle *p) |
write particle information | |
void | write_particle_data (const ParticleData *d) |
write particle data information | |
bool | write_end_listing () |
write end tag | |
void | output (const double &) |
write double | |
void | output (const float &) |
write float | |
void | output (const int &) |
write int | |
void | output (const long int &) |
write long int | |
void | output (const char &) |
write a single character |
event input/output in ascii format for machine reading extended format contains HeavyIon and PdfInfo classes
Definition at line 65 of file IO_ExtendedAscii.h.
HepMC::IO_ExtendedAscii::IO_ExtendedAscii | ( | const char * | filename = "IO_ExtendedAscii.dat" , |
|
std::ios::openmode | mode = std::ios::out | |||
) |
constructor requiring a file name and std::ios mode
Definition at line 19 of file IO_ExtendedAscii.cc.
HepMC::IO_ExtendedAscii::~IO_ExtendedAscii | ( | ) | [virtual] |
void HepMC::IO_ExtendedAscii::write_event | ( | const GenEvent * | evt | ) | [virtual] |
write this event
Writes evt to m_file. It does NOT delete the event after writing.
Implements HepMC::IO_BaseClass.
Definition at line 57 of file IO_ExtendedAscii.cc.
References HepMC::GenEvent::alphaQCD(), HepMC::GenEvent::alphaQED(), HepMC::GenVertex::barcode(), HepMC::GenEvent::beam_particles(), HepMC::WeightContainer::begin(), HepMC::WeightContainer::end(), HepMC::GenEvent::event_number(), HepMC::GenEvent::event_scale(), HepMC::GenEvent::heavy_ion(), HepMC::GenEvent::mpi(), output(), HepMC::GenEvent::pdf_info(), HepMC::GenEvent::random_states(), HepMC::GenEvent::signal_process_id(), HepMC::GenEvent::signal_process_vertex(), HepMC::WeightContainer::size(), v, HepMC::versionName(), HepMC::GenEvent::vertices_begin(), HepMC::GenEvent::vertices_end(), HepMC::GenEvent::vertices_size(), HepMC::GenEvent::weights(), write_beam_particles(), write_heavy_ion(), HepMC::CommonIO::write_IO_ExtendedAscii_Key(), write_pdf_info(), and write_vertex().
bool HepMC::IO_ExtendedAscii::fill_next_event | ( | GenEvent * | evt | ) | [virtual] |
get the next event
Implements HepMC::IO_BaseClass.
Definition at line 111 of file IO_ExtendedAscii.cc.
References HepMC::extascii, HepMC::CommonIO::find_end_key(), HepMC::CommonIO::find_file_type(), and HepMC::CommonIO::read_io_extendedascii().
void HepMC::IO_ExtendedAscii::write_particle_data_table | ( | const ParticleDataTable * | ) | [virtual] |
write this ParticleDataTable
Implements HepMC::IO_BaseClass.
Definition at line 188 of file IO_ExtendedAscii.cc.
References HepMC::ParticleDataTable::begin(), HepMC::ParticleDataTable::end(), write_end_listing(), and write_particle_data().
bool HepMC::IO_ExtendedAscii::fill_particle_data_table | ( | ParticleDataTable * | ) | [virtual] |
fill this ParticleDataTable
Implements HepMC::IO_BaseClass.
Definition at line 208 of file IO_ExtendedAscii.cc.
References HepMC::extascii_pdt, HepMC::CommonIO::find_end_key(), HepMC::CommonIO::find_file_type(), HepMC::CommonIO::read_io_particle_data_table(), and HepMC::ParticleDataTable::set_description().
void HepMC::IO_ExtendedAscii::write_comment | ( | const std::string | comment | ) |
insert a comment directly into the output file --- normally you only want to do this at the beginning or end of the file. All comments are preceded with "HepMC::IO_ExtendedAscii-COMMENT\n"
Definition at line 173 of file IO_ExtendedAscii.cc.
References write_end_listing().
int HepMC::IO_ExtendedAscii::rdstate | ( | ) | const [inline] |
void HepMC::IO_ExtendedAscii::clear | ( | ) | [inline] |
void HepMC::IO_ExtendedAscii::print | ( | std::ostream & | ostr = std::cout |
) | const [virtual] |
write to ostr
Reimplemented from HepMC::IO_BaseClass.
Definition at line 47 of file IO_ExtendedAscii.cc.
void HepMC::IO_ExtendedAscii::write_vertex | ( | GenVertex * | ) | [protected] |
write vertex information
Definition at line 256 of file IO_ExtendedAscii.cc.
References output(), v, and write_particle().
Referenced by write_event().
void HepMC::IO_ExtendedAscii::write_beam_particles | ( | std::pair< HepMC::GenParticle *, HepMC::GenParticle * > | ) | [protected] |
write beam particle information
Definition at line 302 of file IO_ExtendedAscii.cc.
Referenced by write_event().
void HepMC::IO_ExtendedAscii::write_heavy_ion | ( | HeavyIon * | ) | [protected] |
write heavy ion information
Definition at line 319 of file IO_ExtendedAscii.cc.
References HepMC::HeavyIon::eccentricity(), HepMC::HeavyIon::event_plane_angle(), HepMC::HeavyIon::impact_parameter(), HepMC::HeavyIon::N_Nwounded_collisions(), HepMC::HeavyIon::Ncoll(), HepMC::HeavyIon::Ncoll_hard(), HepMC::HeavyIon::Npart_proj(), HepMC::HeavyIon::Npart_targ(), HepMC::HeavyIon::Nwounded_N_collisions(), HepMC::HeavyIon::Nwounded_Nwounded_collisions(), output(), HepMC::HeavyIon::sigma_inel_NN(), HepMC::HeavyIon::spectator_neutrons(), and HepMC::HeavyIon::spectator_protons().
Referenced by write_event().
void HepMC::IO_ExtendedAscii::write_pdf_info | ( | PdfInfo * | ) | [protected] |
write PDF information
Definition at line 363 of file IO_ExtendedAscii.cc.
References HepMC::PdfInfo::id1(), HepMC::PdfInfo::id2(), output(), HepMC::PdfInfo::pdf1(), HepMC::PdfInfo::pdf2(), HepMC::PdfInfo::scalePDF(), HepMC::PdfInfo::x1(), and HepMC::PdfInfo::x2().
Referenced by write_event().
void HepMC::IO_ExtendedAscii::write_particle | ( | GenParticle * | p | ) | [protected] |
write particle information
Definition at line 395 of file IO_ExtendedAscii.cc.
Referenced by write_vertex().
void HepMC::IO_ExtendedAscii::write_particle_data | ( | const ParticleData * | d | ) | [protected] |
write particle data information
Definition at line 420 of file IO_ExtendedAscii.cc.
References HepMC::ParticleData::charge(), HepMC::ParticleData::clifetime(), HepMC::ParticleData::mass(), HepMC::ParticleData::name(), output(), HepMC::ParticleData::pdg_id(), and HepMC::ParticleData::spin().
Referenced by write_particle_data_table().
bool HepMC::IO_ExtendedAscii::write_end_listing | ( | ) | [protected] |
write end tag
Definition at line 438 of file IO_ExtendedAscii.cc.
References HepMC::CommonIO::write_IO_ExtendedAscii_End().
Referenced by write_comment(), write_particle_data_table(), and ~IO_ExtendedAscii().
void HepMC::IO_ExtendedAscii::output | ( | const double & | ) | [inline, protected] |
write double
Definition at line 123 of file IO_ExtendedAscii.h.
Referenced by write_beam_particles(), write_event(), write_heavy_ion(), write_particle(), write_particle_data(), write_pdf_info(), and write_vertex().
void HepMC::IO_ExtendedAscii::output | ( | const float & | ) | [inline, protected] |
void HepMC::IO_ExtendedAscii::output | ( | const int & | ) | [inline, protected] |
void HepMC::IO_ExtendedAscii::output | ( | const long int & | ) | [inline, protected] |
void HepMC::IO_ExtendedAscii::output | ( | const char & | ) | [inline, protected] |