BSON_VALIDATE(3) | libbson | BSON_VALIDATE(3) |
bson_validate - bson_validate()
bool bson_validate (const bson_t *bson, bson_validate_flags_t flags, size_t *offset);
Validates a BSON document by walking through the document and inspecting the keys and values for valid content.
You can modify how the validation occurs through the use of the flags parameter, see bson_validate_with_error() for details.
bson_validate_with_error().
bson_visitor_t can be used for custom validation, example_custom_validation.
Returns true if bson is valid; otherwise false and offset is set to the byte offset where the error was detected.
MongoDB, Inc
2017-present, MongoDB, Inc
June 4, 2021 | 1.17.6 |