19 #include <bsoncxx/document/value.hpp> 20 #include <bsoncxx/document/view.hpp> 21 #include <bsoncxx/stdx/optional.hpp> 23 #include <bsoncxx/config/prelude.hpp> 29 BSONCXX_INLINE_NAMESPACE_BEGIN
34 extern const bool k_silence_doxygen;
54 BSONCXX_API std::string BSONCXX_CALL
to_json(document::view view,
67 BSONCXX_API document::value BSONCXX_CALL
from_json(stdx::string_view json);
69 BSONCXX_INLINE_NAMESPACE_END
72 #include <bsoncxx/config/postlude.hpp> std::string to_json(document::view view, ExtendedJsonMode mode=ExtendedJsonMode::k_legacy)
Converts a BSON document to a JSON string, in extended format.
document::value from_json(stdx::string_view json)
Constructs a new document::value from the provided JSON text.
to produce Relaxed Extended JSON
to produce Legacy Extended JSON
to produce Canonical Extended JSON
ExtendedJsonMode
An enumeration of the types of Extended JSON that the to_json function accepts
Definition: json.hpp:38
Top level namespace for MongoDB C++ BSON functionality.
Definition: element.hpp:24