Project
Loading...
Searching...
No Matches
o2::emcal::RawPayload Class Reference

Class for raw payload excluding raw data headers from one or multiple DMA pages. More...

#include <RawPayload.h>

Public Member Functions

 RawPayload ()=default
 Constructor.
 
 RawPayload (const gsl::span< const uint32_t > payloadwords, int numpages)
 Constructor.
 
 ~RawPayload ()=default
 Destructor.
 
void setNumberOfPages (int numpages)
 Set the number of pages contributing to the current payload.
 
void appendPayloadWords (const gsl::span< const uint32_t > payloadwords)
 Append many words to the current payload (usually of a given DMA page)
 
void appendPayloadWord (uint32_t payloadword)
 Append single payload word to the current payload.
 
void increasePageCount ()
 Increase the page counter of the current payload.
 
const std::vector< uint32_t > & getPayloadWords () const
 Get the payload words (as 32 bit words) contributing to the current payload.
 
int getNumberOfPages () const
 Get the number of pages contributing to the payload.
 
void reset ()
 Resetting payload words and page counter.
 
int getPayloadSize () const
 Get the size of the payload.
 

Detailed Description

Class for raw payload excluding raw data headers from one or multiple DMA pages.

Author
Markus Fasel marku.nosp@m.s.fa.nosp@m.sel@c.nosp@m.ern..nosp@m.ch, Oak Ridge National Laboratory
Since
Nov 14, 2019

Container of 32-bit words in the current payload which can come from a single DMA page or, in case the payload had to be split into multiple pages due to exceeding of the page size, from multiple DMA pages. A page counter provides the amount of DMA pages contributing to the current payload.

Definition at line 36 of file RawPayload.h.

Constructor & Destructor Documentation

◆ RawPayload() [1/2]

o2::emcal::RawPayload::RawPayload ( )
default

Constructor.

◆ RawPayload() [2/2]

RawPayload::RawPayload ( const gsl::span< const uint32_t >  payloadwords,
int  numpages 
)

Constructor.

Parameters
payloadwordsPayload words of one or multiple pages
numpagesNumber of DMA pages contributing to the payload

Definition at line 16 of file RawPayload.cxx.

◆ ~RawPayload()

o2::emcal::RawPayload::~RawPayload ( )
default

Destructor.

Member Function Documentation

◆ appendPayloadWord()

void o2::emcal::RawPayload::appendPayloadWord ( uint32_t  payloadword)
inline

Append single payload word to the current payload.

Parameters
payloadwordPayload word to be appended to the current payload

Definition at line 60 of file RawPayload.h.

◆ appendPayloadWords()

void RawPayload::appendPayloadWords ( const gsl::span< const uint32_t >  payloadwords)

Append many words to the current payload (usually of a given DMA page)

Parameters
payloadwordsPayload words to be appened to the current payload

Definition at line 24 of file RawPayload.cxx.

◆ getNumberOfPages()

int o2::emcal::RawPayload::getNumberOfPages ( ) const
inline

Get the number of pages contributing to the payload.

Returns
Number of pages

Definition at line 71 of file RawPayload.h.

◆ getPayloadSize()

int o2::emcal::RawPayload::getPayloadSize ( ) const
inline

Get the size of the payload.

Returns
Size of the payload

Definition at line 78 of file RawPayload.h.

◆ getPayloadWords()

const std::vector< uint32_t > & o2::emcal::RawPayload::getPayloadWords ( ) const
inline

Get the payload words (as 32 bit words) contributing to the current payload.

Returns
Words of the current payload

Definition at line 67 of file RawPayload.h.

◆ increasePageCount()

void o2::emcal::RawPayload::increasePageCount ( )
inline

Increase the page counter of the current payload.

Definition at line 63 of file RawPayload.h.

◆ reset()

void RawPayload::reset ( )

Resetting payload words and page counter.

Definition at line 31 of file RawPayload.cxx.

◆ setNumberOfPages()

void o2::emcal::RawPayload::setNumberOfPages ( int  numpages)
inline

Set the number of pages contributing to the current payload.

Parameters
numpagesNumber of DMA pages contributing to the payload

Definition at line 52 of file RawPayload.h.


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