From ee9e078a5c107b3bce7c98c28d2a66c850558c89 Mon Sep 17 00:00:00 2001 From: Qianqian Fang Date: Tue, 22 Feb 2022 07:44:28 -0500 Subject: [PATCH] amalgamate code --- single_include/nlohmann/json.hpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/single_include/nlohmann/json.hpp b/single_include/nlohmann/json.hpp index a5bcf37e6..ad7cb827c 100644 --- a/single_include/nlohmann/json.hpp +++ b/single_include/nlohmann/json.hpp @@ -21738,6 +21738,8 @@ class basic_json // NOLINT(cppcoreguidelines-special-member-functions,hicpp-spec binary_writer(o).write_ubjson(j, use_size, use_type); } + /// @brief create a BJData serialization of a given JSON value + /// @sa https://json.nlohmann.me/api/basic_json/to_bjdata/ static std::vector to_bjdata(const basic_json& j, const bool use_size = false, const bool use_type = false) @@ -21747,12 +21749,16 @@ class basic_json // NOLINT(cppcoreguidelines-special-member-functions,hicpp-spec return result; } + /// @brief create a BJData serialization of a given JSON value + /// @sa https://json.nlohmann.me/api/basic_json/to_bjdata/ static void to_bjdata(const basic_json& j, detail::output_adapter o, const bool use_size = false, const bool use_type = false) { binary_writer(o).write_ubjson(j, use_size, use_type, true, true); } + /// @brief create a BJData serialization of a given JSON value + /// @sa https://json.nlohmann.me/api/basic_json/to_bjdata/ static void to_bjdata(const basic_json& j, detail::output_adapter o, const bool use_size = false, const bool use_type = false) { @@ -21951,7 +21957,7 @@ class basic_json // NOLINT(cppcoreguidelines-special-member-functions,hicpp-spec /// @brief create a JSON value from an input in BJData format - /// @sa https://github.com/NeuroJSON/bjdata/blob/master/Binary_JData_Specification.md + /// @sa https://json.nlohmann.me/api/basic_json/from_bjdata/ template JSON_HEDLEY_WARN_UNUSED_RESULT static basic_json from_bjdata(InputType&& i, @@ -21966,7 +21972,7 @@ class basic_json // NOLINT(cppcoreguidelines-special-member-functions,hicpp-spec } /// @brief create a JSON value from an input in BJData format - /// @sa https://github.com/NeuroJSON/bjdata/blob/master/Binary_JData_Specification.md + /// @sa https://json.nlohmann.me/api/basic_json/from_bjdata/ template JSON_HEDLEY_WARN_UNUSED_RESULT static basic_json from_bjdata(IteratorType first, IteratorType last,