gaps-online-software 0.10
online software for the TOF system for the GAPS experiment
Loading...
Searching...
No Matches
Gaps::TofPacketReader Class Reference

#include <io.hpp>

Public Member Functions

 TofPacketReader (String filename)
 
 TofPacketReader (const TofPacketReader &)=delete
 
void set_filename (String filename)
 
auto get_next_packet () -> r::Result< TofPacket, Gaps::IOError >
 Walk over the file and return the next packet.
 
auto get_filename () const -> std::string
 Return the filename we assigned.
 
auto is_exhausted () const -> bool
 
auto n_packets_read () const -> usize
 

Detailed Description

Read serialized TofPackets from a file and emit them as packets

Member Function Documentation

◆ is_exhausted()

auto Gaps::TofPacketReader::is_exhausted ( ) const -> bool

All packets have been read from the file. If they should be read again, the reader has to be created again

◆ n_packets_read()

auto Gaps::TofPacketReader::n_packets_read ( ) const -> usize

The number of files this reader has read from the file

◆ set_filename()

void Gaps::TofPacketReader::set_filename ( String  filename)

Set a filename where to read packets from. This is a binary file format, typically ending in ".tof.gaps"


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