openDAQ
Open data acquisition platform
Tail reader
+ Collaboration diagram for Tail reader:

Detailed Description

Classes

struct  ITailReader
 A reader that only ever reads the last N samples, subsequent calls may result in overlapping data. More...
 
struct  ITailReaderBuilder
 Builder component of Tail reader objects. Contains setter methods to configure the Tail reader parameters and a build method that builds the Unit object. More...
 
class  TailReaderBuilderPtr
 Builder component of Tail reader objects. Contains setter methods to configure the Tail reader parameters and a build method that builds the Unit object. More...
 
class  TailReaderPtr
 A reader that only ever reads the last N samples, subsequent calls may result in overlapping data. More...
 

Functions

daq::TailReaderStatusPtr read (void *values, daq::SizeT *count) const
 Copies at maximum the next count unread samples to the values buffer. The amount actually read is returned through the count parameter. More...
 
daq::TailReaderStatusPtr readWithDomain (void *values, void *domain, daq::SizeT *count) const
 Copies at maximum the next count unread samples and clock-stamps to the values and stamps buffers. The amount actually read is returned through the count parameter. More...
 
daq::SizeT getHistorySize () const
 The maximum amount of samples in history to keep. More...
 

Function Documentation

◆ getHistorySize()

daq::SizeT getHistorySize ( ) const
inline

The maximum amount of samples in history to keep.

Returns
The history size.

◆ read()

daq::TailReaderStatusPtr read ( void *  values,
daq::SizeT *  count 
) const
inline

Copies at maximum the next count unread samples to the values buffer. The amount actually read is returned through the count parameter.

Parameters
[in]valuesThe buffer that the samples will be copied to. The buffer must be a contiguous memory big enough to receive count amount of samples.
[in,out]countThe maximum amount of samples to be read. If the count is less than available the parameter value is set to the actual amount and only the available samples are returned. The rest of the buffer is not modified or cleared.
[out]statusRepresents the status of the reader.

◆ readWithDomain()

daq::TailReaderStatusPtr readWithDomain ( void *  values,
void *  domain,
daq::SizeT *  count 
) const
inline

Copies at maximum the next count unread samples and clock-stamps to the values and stamps buffers. The amount actually read is returned through the count parameter.

Parameters
[in]valuesThe buffer that the data values will be copied to. The buffer must be a contiguous memory big enough to receive count amount of samples.
[in]domainThe buffer that the domain values will be copied to. The buffer must be a contiguous memory big enough to receive count amount of clock-stamps.
[in,out]countThe maximum amount of samples to be read. If the count is less than available the parameter value is set to the actual amount and only the available samples are returned. The rest of the buffer is not modified or cleared.
[out]statusRepresents the status of the reader.