Create a thread‐aware lock‐free queue of the specified capacity.
Synopsis
Declared in <bdlcc_fixedqueue.h>
explicit
FixedQueue(
std::size_t capacity,
bslma::Allocator* basicAllocator = 0);
Description
Create a thread‐aware lock‐free queue having the specified capacity. Optionally specify a basicAllocator used to supply memory. If basicAllocator is 0, the currently installed default allocator is used. The behavior is undefined unless 0 < capacity and capacity <= bdlcc::FixedQueueIndexManager::k_MAX_CAPACITY.
Parameters
Name |
Description |
capacity |
maximum number of elements the queue can hold |
basicAllocator |
allocator used to supply memory |
Created with MrDocs