![]() |
VRS
A file format for sensor data.
|
Elementary part of a DataSource for a simple block of memory. More...
#include <DataSource.h>
Public Member Functions | |
DataSourceChunk (const DataSourceChunk &other)=delete | |
Not copyable as there are derived classes that aren't safe to copy from the base class. | |
const DataSourceChunk & | operator= (const DataSourceChunk &other)=delete |
DataSourceChunk () | |
Empty DataSourceChunk. | |
DataSourceChunk (const void *_data, size_t _size) | |
Constructor for a raw pointer + size. | |
template<typename T > | |
DataSourceChunk (const vector< T > &vectorT) | |
Constructor for a vector<T> of objects of POD type T. | |
template<typename T , std::enable_if_t< std::is_trivially_copyable< T >::value, int > = 0, typename = typename std::enable_if<!is_pointer<T>::value, T>::type> | |
DataSourceChunk (const T &object) | |
Constructor for a trivially copyable type T. | |
virtual void | fillAndAdvanceBuffer (uint8_t *&buffer) const |
const void * | data () const |
size_t | size () const |
For performance, do not make this method virtual. | |
Elementary part of a DataSource for a simple block of memory.
Class possibly referencing a buffer of bytes, specified in 4 possible different ways:
This class is meant to simplify the manipulation of a buffer of bytes, for use by DataSource. Only the constructors and assignment operators are meant to be used by code outside of DataSource.
|
virtual |
Copy the data (if any), and update the provided buffer pointer accordingly. The number of bytes copied must be the exact size specified in the constructor.
Reimplemented in vrs::NonContiguousChunk.