BSON_VECTOR_PACKED_BIT_VIEW_PACK_BOOL(3)

Pack a contiguous block of elements from a C bool array into a bson_vector_packed_bit_view_t.

SYNOPSIS

    bool
    bson_vector_packed_bit_view_pack_bool (bson_vector_packed_bit_view_t view,
                                           const bool *unpacked_values,
                                           size_t element_count,
                                           size_t vector_offset_elements)

PARAMETERS

•   view: A valid bson_vector_packed_bit_view_t.

•   unpacked_values: Location where the bool elements will be packed from.

•   element_count: Number of elements to pack.

•   vector_offset_elements: The vector index of the first element to pack.

DESCRIPTION

Elements are packed into individual Vector bits from a C bool array.

RETURNS

If the element_count and vector_offset_elements parameters overflow the bounds of the Vector, returns false without taking any other action. If the parameters are in range, this is guaranteed to succeed. On success, returns true and writes to element_count elements in the Vector starting at vector_offset_elements.

AUTHOR
MongoDB, Inc

COPYRIGHT
2009-present, MongoDB, Inc.