lockfree queue capable of storing indices 0,1,... Capacity-1
More...
#include <index_queue.hpp>
|
using | value_t = ValueType |
|
|
template<typename ElementType , uint64_t Cap> |
class | LockFreeQueue |
|
template<typename ElementType , uint64_t Cap> |
class | ResizeableLockFreeQueue |
|
template<uint64_t Capacity, typename ValueType = uint64_t>
class iox::concurrent::IndexQueue< Capacity, ValueType >
lockfree queue capable of storing indices 0,1,... Capacity-1
◆ capacity()
template<uint64_t Capacity, typename ValueType >
◆ empty()
template<uint64_t Capacity, typename ValueType >
check whether the queue is empty
- Returns
- true iff the queue is empty note that if the queue is used concurrently it might not be empty anymore after the call (but it was at some point during the call)
◆ pop()
template<uint64_t Capacity, typename ValueType >
pop an index from the queue in FIFO order if the queue not empty
- Returns
- index if the queue was is empty, nullopt oterwise
◆ popIfFull()
template<uint64_t Capacity, typename ValueType >
pop an index from the queue in FIFO order if the queue is full
- Returns
- index if the queue was full, nullopt otherwise
◆ popIfSizeIsAtLeast()
template<uint64_t Capacity, typename ValueType >
pop an index from the queue in FIFO order if the queue contains at least a specified number number of elements
- Parameters
-
size | the number of elements needed to successfully perform the pop |
- Returns
- index if the queue contains size elements, nullopt otherwise
◆ push()
template<uint64_t Capacity, typename ValueType >
push index into the queue in FIFO order
- Parameters
-
index | to be pushed note that do the way it is supposed to be used we cannot overflow (the number of indices available is bounded and the capacity is large enough to hold them all) |
The documentation for this class was generated from the following files:
- iceoryx_utils/internal/concurrent/lockfree_queue/index_queue.hpp
- iceoryx_utils/internal/concurrent/lockfree_queue/index_queue.inl