Write a truncated FIX representation of object to buffer.

Synopsis

Declared in <bdlt_fixutil.h>

static
int
generate(
    char* buffer,
    int bufferLength,
    Date const& object);

Description

Write the FIX representation of the specified object to the specified buffer of the specified bufferLength (in bytes), truncating (if necessary) to bufferLength.

Optionally specify a configuration to affect the format of the generated string. If configuration is not supplied, the process‐wide default value FixUtilConfiguration::defaultConfiguration() is used. Return the number of characters in the formatted string before truncation (not counting a null terminator). If bufferLength indicates sufficient capacity, buffer is null terminated. The behavior is undefined unless 0 <= bufferLength. Note that a buffer of size k_MAX_STRLEN + 1 is large enough to hold any string generated by this component (counting a null terminator, if any).

Return Value

the number of characters written before truncation

Parameters

Name

Description

buffer

destination buffer

bufferLength

capacity of buffer in bytes

object

the value to format

Created with MrDocs