fire v0.19.0
Framework for sImulation and Reconstruction of Events
fire::io::Writer::BufferHandle Class Referenceabstract

Type-less handle to buffers. More...

Inheritance diagram for fire::io::Writer::BufferHandle:
[legend]
Collaboration diagram for fire::io::Writer::BufferHandle:
[legend]

Public Member Functions

 BufferHandle (std::size_t max, HighFive::DataSet s)
 Define the maximum size of the buffer and the dataset we are writing to. More...
 
virtual ~BufferHandle ()=default
 virtual destructor so derived Buffer can be destructed properly
 
virtual void flush ()=0
 Pure virtual flush mechanism. More...
 

Protected Attributes

std::size_t max_len_
 the maximum size of the buffer
 
HighFive::DataSet set_
 the H5 dataset we are writing to
 

Detailed Description

Type-less handle to buffers.

This type-less handle allows us to flush the buffers at the end of processing safely as well as maintain a single map of all buffers we are managing.

Constructor & Destructor Documentation

◆ BufferHandle()

fire::io::Writer::BufferHandle::BufferHandle ( std::size_t  max,
HighFive::DataSet  s 
)
inlineexplicit

Define the maximum size of the buffer and the dataset we are writing to.

Parameters
[in]maxsize of buffer
[in]sdataset to write to

Member Function Documentation

◆ flush()

virtual void fire::io::Writer::BufferHandle::flush ( )
pure virtual

Pure virtual flush mechanism.

This is designed in the derived Buffer where we know the type of data we are flushing to disk. This is also a helpful virtual method so that we can flush the buffers in Writer::flush without know the types stored within them.

Implemented in fire::io::Writer::Buffer< AtomicType >.


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