Toolbox snapshot
The Reactive C++ Toolbox
|
#include <toolbox/util/RingBuffer.hpp>
Public Member Functions | |
RingBuffer (std::size_t capacity) | |
~RingBuffer ()=default | |
RingBuffer (const RingBuffer &)=delete | |
RingBuffer & | operator= (const RingBuffer &)=delete |
RingBuffer (RingBuffer &&) noexcept=default | |
RingBuffer & | operator= (RingBuffer &&) noexcept=default |
bool | empty () const noexcept |
Returns true if the container is empty. | |
bool | full () const noexcept |
Returns true if the container is full. | |
std::size_t | available () const noexcept |
Returns the number of available elements. | |
std::size_t | capacity () const noexcept |
std::size_t | max_size () const noexcept |
std::size_t | size () const noexcept |
Returns true if the number of elements in the container. | |
const ValueT & | front () const noexcept |
const ValueT & | back () const noexcept |
ValueT & | front () noexcept |
ValueT & | back () noexcept |
void | clear () noexcept |
void | pop () noexcept |
void | push (const ValueT &val) |
template<typename FnT > | |
void | fetch (FnT fn) |
template<typename FnT > | |
void | write (FnT fn) |
Definition at line 28 of file RingBuffer.hpp.
|
inlineexplicit |
Definition at line 30 of file RingBuffer.hpp.
|
default |
|
delete |
|
defaultnoexcept |
|
delete |
|
defaultnoexcept |
|
inlinenoexcept |
Returns true if the container is empty.
Definition at line 47 of file RingBuffer.hpp.
|
inlinenoexcept |
Returns true if the container is full.
Definition at line 49 of file RingBuffer.hpp.
Referenced by toolbox::util::RingBuffer< ValueT >::push(), and toolbox::util::RingBuffer< ValueT >::write().
|
inlinenoexcept |
Returns the number of available elements.
Definition at line 51 of file RingBuffer.hpp.
|
inlinenoexcept |
Returns the maximum number of elements the container can hold. I.e. the container's capacity.
Definition at line 54 of file RingBuffer.hpp.
Referenced by toolbox::util::RingBuffer< ValueT >::max_size().
|
inlinenoexcept |
Returns the maximum number of elements the container can hold. I.e. the container's capacity.
Definition at line 57 of file RingBuffer.hpp.
|
inlinenoexcept |
Returns true if the number of elements in the container.
Definition at line 59 of file RingBuffer.hpp.
Referenced by toolbox::util::RingBuffer< ValueT >::available(), and toolbox::util::RingBuffer< ValueT >::full().
|
inlinenoexcept |
Definition at line 60 of file RingBuffer.hpp.
|
inlinenoexcept |
Definition at line 61 of file RingBuffer.hpp.
|
inlinenoexcept |
Definition at line 63 of file RingBuffer.hpp.
|
inlinenoexcept |
Definition at line 64 of file RingBuffer.hpp.
|
inlinenoexcept |
Definition at line 65 of file RingBuffer.hpp.
|
inlinenoexcept |
Definition at line 66 of file RingBuffer.hpp.
|
inline |
Definition at line 67 of file RingBuffer.hpp.
|
inline |
Definition at line 77 of file RingBuffer.hpp.
|
inline |
Definition at line 84 of file RingBuffer.hpp.