SYNOPSIS

#include <bson.h>

#define BSON_ITER_HOLDS_OID(iter) \
   (bson_iter_type ((iter)) == BSON_TYPE_OID)

const bson_oid_t *
bson_iter_oid (const bson_iter_t *iter);

DESCRIPTION

The bson_iter_oid() function shall fetch the contents of a BSON_TYPE_OID element from iter.

It is invalid to call this function while observing an element other than of type BSON_TYPE_OID.

RETURN VALUE

A pointer to a bson_oid_t that should not be modified or freed.

ERRORS

No errors are defined.

SEE ALSO

AUTHORS

This page was written by MongoDB, Inc.