Return the maximum number of objects of the specified size.

Synopsis

Declared in <bsltf_stdtestallocator.h>

static
size_t
maxSize(size_t elementSize);

Description

Return the maximum number of objects, each taking the specified elementSize bytes of storage, that can potentially be allocated by a StdTestAllocator. Note that this function is mostly about insulating consumers of this component from a standard header, so that this test component does not hide missing header dependencies in testing scenarios.

Return Value

the maximum number of objects of size elementSize

Parameters

Name

Description

elementSize

size in bytes of each object

Created with MrDocs