Implementation of a rate limiting bit pool.
More...
#include <bitpool.h>
Implementation of a rate limiting bit pool.
- Note
- Uses a thread to allow blocking dequeues
Definition at line 52 of file bitpool.h.
◆ BitPool()
◆ ~BitPool()
EMANE::Utils::BitPool::~BitPool |
( |
| ) |
|
|
inline |
◆ get()
std::uint64_t EMANE::Utils::BitPool::get |
( |
std::uint64_t |
u64Request, |
|
|
bool |
bFullFill = true |
|
) |
| |
|
inline |
Gets bits from pool
- Parameters
-
u64Request | request size |
bFullFill | Continue until entire request is fulfilled |
- Returns
- Number outstanding or 0 if disabled
Definition at line 97 of file bitpool.inl.
◆ getCurrentSize()
std::uint64_t EMANE::Utils::BitPool::getCurrentSize |
( |
| ) |
|
|
inline |
Gets current pool size
- Returns
- the current pool size
Definition at line 164 of file bitpool.inl.
◆ setMaxSize()
void EMANE::Utils::BitPool::setMaxSize |
( |
std::uint64_t |
u64NewSize | ) |
|
|
inline |
Set pool size
- Parameters
-
u64NewSize | pool size request in bits |
Definition at line 65 of file bitpool.inl.
The documentation for this class was generated from the following files: