11#ifndef ALICEO2_PHOS_RAWREADERMEMORY_H
12#define ALICEO2_PHOS_RAWREADERMEMORY_H
47 void setRawMemory(
const gsl::span<const char> rawmemory);
62 void nextPage(
bool resetPayload =
true);
84 int getFileSize() const noexcept {
return mRawMemoryBuffer.size(); }
92 bool hasNext()
const {
return mCurrentPosition < mRawMemoryBuffer.size(); }
103 gsl::span<const char> mRawMemoryBuffer;
108 uint64_t mTrailerPayloadWords = 0;
109 uint32_t mCurrentPosition = 0;
111 bool mRawHeaderInitialized =
false;
112 bool mPayloadInitialized =
false;
Information stored in the RCU trailer.
Buffer for PHOS raw pages.
Class for raw payload excluding raw data headers from one or multiple DMA pages.
int getPayloadSize() const
Get the size of the payload.
Reader for raw data produced by the Readout application in in-memory format.
const o2::header::RDHAny & getRawHeader() const
access to the raw header of the current page
int getPayloadSize() const
Return size of the payload.
int getNumberOfPages() const noexcept
get the number of pages in the file
~RawReaderMemory()=default
Destructor.
void setRawMemory(const gsl::span< const char > rawmemory)
set new raw memory chunk
int getFileSize() const noexcept
get the size of the file in bytes
void init()
Initialize the raw stream.
void next()
Read next payload from the stream.
void nextPage(bool resetPayload=true)
Read the next page from the stream (single DMA page)
o2::header::RDHAny decodeRawHeader(const void *headerwords)
const RawPayload & getPayload() const
access to the full raw payload (single or multiple DMA pages)
bool hasNext() const
check if more pages are available in the raw file
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...