|
| | CircularBuffer () |
| int16 | write (const T &instance) |
| | Write a single data item into the buffer.
|
| int16 | writeBuffer (const T *buffer, uint32 size) |
| | Write a buffer of data items into the buffer.
|
| | Queue () |
| int16 | write (const T &instance) |
| | Write a single data item into the queue.
|
| int16 | writeBuffer (const T *buffer, uint32 size) |
| | Write a buffer of data items into the queue.
|
| int16 | read (T &instance) |
| | Read item from the queue and increment the read pointer.
|
| int16 | readBuffer (T *buffer, uint32 max_vals, uint32 &num_vals_read) |
| | Read items from the queue into buffer and increment read pointer.
|
| int16 | pop () |
| | Function to pop one value from the queue and discard it.
|
| int16 | popBuffer (uint32 max_vals, uint32 &num_vals_popped) |
| | Function to pop a specified number of values from the queue.
|
| int16 | peek (T &instance) |
| | Read item from the queue without incrementing the read pointer.
|
| int16 | peekIndex (uint32 index, T &instance) |
| | Peek index relative to the read pointer without incrementing the read pointer.
|
| int16 | peekBuffer (T *buffer, uint32 max_vals, uint32 &num_vals_read) |
| | Read items from the queue without incrementing the read pointer.
|
| void | clear () |
| | Clear the queue entirely.
|
| uint32 | valsAvailable () |
| | Get number of spaces in queue.
|
| uint32 | valsHeld () |
| | Get the number of values held by the queue.
|
template<typename T, uint32 L>
class clockwerk::CircularBuffer< T, L >
Simple Circular Buffer for data storage.
The Circular Buffer class is a simple, templated, first in first out buffer with modifiable type and size that overwrites when it reaches its max.