scoped_bson_t::scoped_bson_t(bsoncxx::stdx::optional<bsoncxx::document::view_or_value> doc) : _is_initialized{doc} { if (doc) { _doc = std::move(doc); doc_to_bson_t(*_doc, &_bson); } }
void scoped_bson_t::init_from_static( bsoncxx::stdx::optional<bsoncxx::document::view_or_value> doc) { if (doc) { _is_initialized = true; _doc = std::move(doc); doc_to_bson_t(*_doc, &_bson); } }
scoped_bson_t::scoped_bson_t(bsoncxx::document::view_or_value doc) : _is_initialized{true}, _doc{std::move(doc)} { doc_to_bson_t(*_doc, &_bson); }
void scoped_bson_t::init_from_static(const bsoncxx::document::view& doc) { _is_initialized = true; doc_to_bson_t(doc, &_bson); }
scoped_bson_t::scoped_bson_t(const bsoncxx::document::view& doc) : _is_initialized(true) { doc_to_bson_t(doc, &_bson); }
static void optional_doc_to_bson_t(const stdx::optional<bsoncxx::document::view>& doc, bson_t* bson) { if (doc) { doc_to_bson_t(*doc, bson); } }
void scoped_bson_t::init_from_static(bsoncxx::document::view_or_value doc) { _is_initialized = true; _doc = doc; doc_to_bson_t(*_doc, &_bson); }