![]() |
![]()
| ![]() |
![]()
Document validation options SYNOPSIS#include <bson/bson-types.h> typedef enum { DESCRIPTIONbson_validate_flags_t is a set of binary flags which may be combined to specify a level of BSON document validation. A value of 0, false, or BSON_VALIDATE_NONE equivalently requests the minimum applicable level of validation. In the context of validation APIs bson_validate(), bson_validate_with_error(), and bson_validate_with_error_and_offset() the minimum validation still guarantees that a document can be successfully traversed by bson_iter_visit_all(). Higher level APIs using this type may have different minimum validation levels. For example, libmongoc functions that take bson_validate_flags_t use 0 to mean the document contents are not visited and malformed headers will not be detected by the client. Each defined flag aside from BSON_VALIDATE_NONE describes an optional validation feature that may be enabled, alone or in combination with other features:
SEE ALSO: bson_validate(), bson_validate_with_error(), bson_validate_with_error_and_offset(). bson_visitor_t can be used for custom validation, Example Custom Validation. AUTHORMongoDB, Inc COPYRIGHT2009-present, MongoDB, Inc.
|