BloombergLP::bdlma::ConcurrentMultipool::reserveCapacity

Reserve capacity for at least numBlocks blocks of the specified size.

Synopsis

Declared in <bdlma_concurrentmultipool.h>

void
reserveCapacity(
    bsls::Types::size_type size,
    int numBlocks);

Description

Reserve memory from this multipool to satisfy memory requests for at least the specified numBlocks having the specified size (in bytes) before the pool replenishes. If size is 0, this method has no effect. The behavior is undefined unless size <= maxPooledBlockSize() and 0 <= numBlocks.

Parameters

NameDescription
sizesize in bytes of each block to reserve
numBlocksminimum number of blocks to reserve