HepMC3 event record library
Public Member Functions | Protected Attributes | Private Attributes
WriterHEPEVTZEUS Class Reference

Detailed Description

GenEvent I/O output to files readable by ZEUS software.

Definition at line 18 of file WriterHEPEVTZEUS.h.

#include <WriterHEPEVTZEUS.h>

+ Inheritance diagram for WriterHEPEVTZEUS:
+ Collaboration diagram for WriterHEPEVTZEUS:

Public Member Functions

 WriterHEPEVTZEUS (const std::string &filename)
 Constructor. More...
 
void write_hepevt_event_header ()
 Write the header. More...
 
void write_hepevt_particle (int index)
 Write particles. More...
 
virtual void write_hepevt_particle (int index, bool iflong=true)
 Write particle to file. More...
 
void write_event (const GenEvent &evt) override
 Write event to file. More...
 
void close () override
 Close file stream. More...
 
bool failed () override
 Get stream error state flag. More...
 
void set_vertices_positions_present (bool iflong)
 set flag if vertex positions are available More...
 
bool get_vertices_positions_present () const
 get flag if vertex positions are available More...
 
void set_run_info (shared_ptr< GenRunInfo > run)
 Set the global GenRunInfo object. More...
 
shared_ptr< GenRunInforun_info () const
 Get the global GenRunInfo object. More...
 
void set_options (const std::map< std::string, std::string > &options)
 Set options. More...
 
std::map< std::string, std::string > get_options () const
 Set options. More...
 

Protected Attributes

std::ofstream m_file
 Output file. More...
 
std::ostream * m_stream
 Output stream. More...
 
char * hepevtbuffer
 Pointer to HEPEVT Fortran common block/C struct. More...
 
int m_events_count
 Events count. Needed to generate unique object name. More...
 
bool m_vertices_positions_present
 true if vertex positions are available More...
 
std::map< std::string, std::string > m_options
 options More...
 

Private Attributes

shared_ptr< GenRunInfom_run_info
 The global GenRunInfo object. More...
 

Constructor & Destructor Documentation

◆ WriterHEPEVTZEUS()

WriterHEPEVTZEUS ( const std::string &  filename)

Constructor.

Definition at line 5 of file WriterHEPEVTZEUS.cc.

Member Function Documentation

◆ close()

void close ( )
overridevirtualinherited

Close file stream.

Implements Writer.

Definition at line 73 of file WriterHEPEVT.cc.

References WriterHEPEVT::m_stream.

◆ failed()

bool failed ( )
overridevirtualinherited

Get stream error state flag.

Implements Writer.

Definition at line 80 of file WriterHEPEVT.cc.

References WriterHEPEVT::m_file.

◆ get_options()

std::map<std::string, std::string> get_options ( ) const
inlineinherited

Set options.

Definition at line 61 of file Writer.h.

References Writer::m_options.

◆ get_vertices_positions_present()

bool get_vertices_positions_present ( ) const
inherited

get flag if vertex positions are available

Definition at line 87 of file WriterHEPEVT.cc.

References WriterHEPEVT::m_vertices_positions_present.

◆ run_info()

shared_ptr<GenRunInfo> run_info ( ) const
inlineinherited

Get the global GenRunInfo object.

Definition at line 47 of file Writer.h.

References Writer::m_run_info.

◆ set_options()

void set_options ( const std::map< std::string, std::string > &  options)
inlineinherited

Set options.

Definition at line 56 of file Writer.h.

References Writer::m_options.

◆ set_run_info()

void set_run_info ( shared_ptr< GenRunInfo run)
inlineinherited

Set the global GenRunInfo object.

Definition at line 42 of file Writer.h.

References Writer::m_run_info.

◆ set_vertices_positions_present()

void set_vertices_positions_present ( bool  iflong)
inherited

set flag if vertex positions are available

Definition at line 85 of file WriterHEPEVT.cc.

References WriterHEPEVT::m_vertices_positions_present.

◆ write_event()

void write_event ( const GenEvent evt)
overridevirtualinherited

◆ write_hepevt_event_header()

void write_hepevt_event_header ( )
virtual

Write the header.

Reimplemented from WriterHEPEVT.

Definition at line 6 of file WriterHEPEVTZEUS.cc.

References HEPEVT_Wrapper::event_number(), WriterHEPEVT::m_stream, and HEPEVT_Wrapper::number_entries().

◆ write_hepevt_particle() [1/2]

void write_hepevt_particle ( int  index)

◆ write_hepevt_particle() [2/2]

void write_hepevt_particle ( int  index,
bool  iflong = true 
)
virtualinherited

Field Documentation

◆ hepevtbuffer

char* hepevtbuffer
protectedinherited

Pointer to HEPEVT Fortran common block/C struct.

Definition at line 79 of file WriterHEPEVT.h.

◆ m_events_count

int m_events_count
protectedinherited

Events count. Needed to generate unique object name.

Definition at line 80 of file WriterHEPEVT.h.

◆ m_file

std::ofstream m_file
protectedinherited

Output file.

Definition at line 77 of file WriterHEPEVT.h.

◆ m_options

std::map<std::string, std::string> m_options
protectedinherited

options

Definition at line 68 of file Writer.h.

◆ m_run_info

shared_ptr<GenRunInfo> m_run_info
privateinherited

The global GenRunInfo object.

Definition at line 73 of file Writer.h.

◆ m_stream

std::ostream* m_stream
protectedinherited

Output stream.

Definition at line 78 of file WriterHEPEVT.h.

◆ m_vertices_positions_present

bool m_vertices_positions_present
protectedinherited

true if vertex positions are available

Definition at line 81 of file WriterHEPEVT.h.


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