Prepend bytes to dest, preferring existing then spare capacity.
Synopsis
Declared in <bdlbb_blobutil.h>
static
void
prependWithCapacityBuffer(
Blob* dest,
BlobBuffer* buffer,
char const* source,
int length);
Description
Prepend the specified length bytes from the specified source address to the specified dest. Use the existing capacity in dest first if 0 == dest‐>length(), followed by that in the buffer, and finally allocate from the blob buffer factory associated with the dest. Load any unused space into the specified buffer. The behavior is undefined unless the range [source, source + length)] represents a readable sequence of memory.
Parameters
Name |
Description |
dest |
destination blob |
buffer |
in/out spare capacity buffer |
source |
contiguous source address |
length |
number of bytes to prepend |
Created with MrDocs