BloombergLP::bdld::Datum::createUninitializedBinary

Create an uninitialized binary buffer and load a datum referring to it.

Synopsis

Declared in <bdld_datum.h>

static
void*
createUninitializedBinary(
    Datum* result,
    SizeType size,
    AllocatorType const& allocator);

Description

Load the specified result with a reference to a newly created binary buffer of the specified size, using the specified allocator to supply memory, and return the address of this buffer. The behavior is undefined unless size <= UINT_MAX. Note that the caller is responsible for initializing the returned buffer with binary data.

Return Value

the address of the uninitialized binary buffer

Parameters

NameDescription
resultreceives the datum that refers to the buffer
sizesize of the binary buffer in bytes
allocatormemory allocator to use