|
| | DiskBuffer (size_t capacity, const std::string &fileName, bool deleteFileAfterClose=true) |
| | The constructor prepares file on disk and creates an instance. More...
|
| |
| void | reset () override |
| | Function resets all positions to default value. More...
|
| |
| FileHandler< T > & | getHandler () |
| | Returns buffer (file) handler. More...
|
| |
| size_t | write (const T *samples, size_t samplesCount, size_t pos) override |
| | Writes samples into buffer. More...
|
| |
| size_t | read (T *samples, size_t samplesCount, const size_t pos) override |
| | Reads from buffer into samples. More...
|
| |
| T * | getData () const override |
| | Function returns pointer to the internal buffer. More...
|
| |
| bool | validateReadPos (size_t readPos) |
| | Function validates whether reading position is inside buffer boundaries. More...
|
| |
| | FifoBufferBase (size_t aCapacity=0) |
| | The constructor creates an instance. More...
|
| |
| size_t | getReadPos () override |
| | Function returns current read position. More...
|
| |
| size_t | getWritePos () override |
| | Function returns current write position. More...
|
| |
| size_t | getSize () override |
| | Function returns current buffer size in values. More...
|
| |
| size_t | getRemainingSize () override |
| | Function returns remaining size in values. More...
|
| |
| virtual void | setCapacity (size_t aCapacity) |
| | Function allocates memory at the heap. More...
|
| |
| size_t | getCapacity () const override |
| | Function returns buffer capacity in values. More...
|
| |
| virtual bool | isFull () |
| | Function returns true if buffer is full. More...
|
| |
| std::recursive_mutex & | getLock () override |
| | Function return locking object. More...
|
| |
| void | incrementReadPosition (size_t pos) override |
| | Function increments read position for N values. More...
|
| |
| void | incrementWritePosition (size_t pos) override |
| | Function increments write position for N values. More...
|
| |
| size_t | readSamples (T *samples, size_t samplesCount, bool incrementPosition=true) override |
| | Function reads the samples from buffer. More...
|
| |
| virtual size_t | readSamplesAt (T *samples, size_t samplesCount, bool incrementPosition=true, size_t readOffset=0) |
| | Function reads the samples from buffer. More...
|
| |
| size_t | writeSamples (const T *samples, size_t samplesCount, bool incrementPosition=true) override |
| | Function pushes the samples into buffer. More...
|
| |
template<typename T>
class DiskBuffer< T >
The class DiskBuffer implements a first-in-first-out (FIFO) data structure on physical disc.