Implementation of a Simple Circular Buffer. Instead of comparing the position of the read and write pointer in order to figure out if we still have characters available or space left to write we keep track of the actual length which is easier to follow.
More...
#include <RingBuffer.h>
Implementation of a Simple Circular Buffer. Instead of comparing the position of the read and write pointer in order to figure out if we still have characters available or space left to write we keep track of the actual length which is easier to follow.
◆ RingBuffer()
tiny_dlna::RingBuffer::RingBuffer |
( |
int |
size = 512 | ) |
|
|
inline |
◆ available()
int tiny_dlna::RingBuffer::available |
( |
| ) |
|
|
inline |
◆ availableToWrite()
int tiny_dlna::RingBuffer::availableToWrite |
( |
| ) |
|
|
inline |
◆ peek()
int tiny_dlna::RingBuffer::peek |
( |
| ) |
|
|
inline |
◆ read() [1/2]
int tiny_dlna::RingBuffer::read |
( |
| ) |
|
|
inline |
◆ read() [2/2]
int tiny_dlna::RingBuffer::read |
( |
uint8_t * |
str, |
|
|
int |
len |
|
) |
| |
|
inline |
◆ resize()
void tiny_dlna::RingBuffer::resize |
( |
int |
size | ) |
|
|
inline |
◆ write() [1/2]
size_t tiny_dlna::RingBuffer::write |
( |
uint8_t * |
str, |
|
|
int |
len |
|
) |
| |
|
inline |
◆ write() [2/2]
size_t tiny_dlna::RingBuffer::write |
( |
uint8_t |
ch | ) |
|
|
inline |
◆ actual_len
int tiny_dlna::RingBuffer::actual_len = 0 |
|
protected |
◆ actual_read_pos
int tiny_dlna::RingBuffer::actual_read_pos = 0 |
|
protected |
◆ actual_write_pos
int tiny_dlna::RingBuffer::actual_write_pos = 0 |
|
protected |
◆ buffer
Vector<char> tiny_dlna::RingBuffer::buffer {0} |
|
protected |
◆ max_len
int tiny_dlna::RingBuffer::max_len |
|
protected |
The documentation for this class was generated from the following file: