Sming Framework API
Sming - Open Source framework for high efficiency WiFi SoC ESP8266 native development with C++ language.
|
Public Member Functions | |
bool | add (const Type &obj) |
bool | pull (Type *dest) |
Type * | peek (size_t num) |
bool | isFull () const |
size_t | numElements () const |
bool | isEmpty () const |
Protected Member Functions | |
size_t | getTail () const |
Protected Attributes | |
Type | _buf [MaxElements] |
size_t | _head |
size_t | _numElements |
|
inline |
Add element obj to the buffer Return: true on success
|
inlineprotected |
Calculates the index in the array of the oldest element Return: index in array of element
|
inline |
Return: true if buffer is empty
|
inline |
Return: true if buffer is full
|
inline |
Return: number of elements in buffer
|
inline |
Peek at num'th element in the buffer Return: a pointer to the num'th element
|
inline |
Remove last element from buffer, and copy it to dest Return: true on success