clas12root
Loading...
Searching...
No Matches
clas12::clas12writer Class Reference

#include <clas12writer.h>

Public Member Functions

 clas12writer ()=default
 clas12writer (std::string filename)
virtual ~clas12writer ()=default
void addSchema (std::string schemaName, hipo::dictionary &factory)
void addSchemas (hipo::dictionary &factory)
 add schemas to writer
void assignReader (clas12reader &c12reader)
void clearEvent ()
void closeWriter ()
 closes hipo::writer, writes out events still on buffer
hipo::writer & getWriter ()
bool hasSchema (std::string schemaName)
 check if the writer contains a given schema
bool isOpen () const
void openFile ()
 opens file in hipo::writer, only open it once.
void processSpecialBanks (std::string inputFilename)
 Write the special banks (tag 1) to the output hipo file.
bool savedBankName (std::string name)
 checks if the name of a bank is kept in memory to be skipped
void setFile (const std::string &file)
void setTag (long tag)
void skipBank (std::string bankName)
 adds a bank name to the list of banks to skip
void writeEvent ()
 pass bank information to hipo::writer to write out events
void writeSpecialBanks (bool specialBanksBool)

Constructor & Destructor Documentation

◆ clas12writer() [1/2]

clas12::clas12writer::clas12writer ( )
default

◆ clas12writer() [2/2]

clas12::clas12writer::clas12writer ( std::string filename)

◆ ~clas12writer()

virtual clas12::clas12writer::~clas12writer ( )
virtualdefault

Member Function Documentation

◆ addSchema()

void clas12::clas12writer::addSchema ( std::string schemaName,
hipo::dictionary & factory )

◆ addSchemas()

void clas12::clas12writer::addSchemas ( hipo::dictionary & factory)

add schemas to writer

◆ assignReader()

void clas12::clas12writer::assignReader ( clas12reader & c12reader)

Assign a reader to the writer, allows for banks and schema info to be passed from reader. Do this here to allow multiple files to be read by different readers but written into one file.

◆ clearEvent()

void clas12::clas12writer::clearEvent ( )

◆ closeWriter()

void clas12::clas12writer::closeWriter ( )

closes hipo::writer, writes out events still on buffer

◆ getWriter()

hipo::writer & clas12::clas12writer::getWriter ( )
inline

◆ hasSchema()

bool clas12::clas12writer::hasSchema ( std::string schemaName)

check if the writer contains a given schema

◆ isOpen()

bool clas12::clas12writer::isOpen ( ) const
inline

◆ openFile()

void clas12::clas12writer::openFile ( )

opens file in hipo::writer, only open it once.

◆ processSpecialBanks()

void clas12::clas12writer::processSpecialBanks ( std::string inputFilename)

Write the special banks (tag 1) to the output hipo file.

◆ savedBankName()

bool clas12::clas12writer::savedBankName ( std::string name)

checks if the name of a bank is kept in memory to be skipped

◆ setFile()

void clas12::clas12writer::setFile ( const std::string & file)
inline

◆ setTag()

void clas12::clas12writer::setTag ( long tag)

Sets a tag for the events record in the writer. For the tag to apply to the correct events need to write record using flush().

◆ skipBank()

void clas12::clas12writer::skipBank ( std::string bankName)
inline

adds a bank name to the list of banks to skip

◆ writeEvent()

void clas12::clas12writer::writeEvent ( )

pass bank information to hipo::writer to write out events

◆ writeSpecialBanks()

void clas12::clas12writer::writeSpecialBanks ( bool specialBanksBool)
inline

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