Commit daa3ca8a authored by Julian Becker's avatar Julian Becker

BSON: Adjusted documentation of `binary_writer::to_bson()`

parent 5bccacda
......@@ -6609,6 +6609,7 @@ class basic_json
number_integer | 2147483648..9223372036854775807 | int64 | 0x12
number_unsigned | 0..2147483647 | int32 | 0x10
number_unsigned | 2147483648..9223372036854775807 | int64 | 0x12
number_unsigned | 9223372036854775808..18446744073709551615| -- | --
number_float | *any value* | double | 0x01
string | *any value* | string | 0x02
array | *any value* | document | 0x04
......@@ -6616,8 +6617,12 @@ class basic_json
@warning The mapping is **incomplete**, since only JSON-objects (and things
contained therein) can be serialized to BSON.
Also, integers larger than 9223372036854775807 cannot be serialized to BSON.
@pre The input `j` is required to be an object: `j.is_object() == true`
@throw out_of_range.407 if `j.is_number_unsigned() && j.get<std::uint64_t>() > 9223372036854775807`
@throw type_error.317 if `!j.is_object()`
@pre The input `j` is required to be an object: `j.is_object() == true`.
@note Any BSON output created via @ref to_bson can be successfully parsed
by @ref from_bson.
......
......@@ -18195,6 +18195,7 @@ class basic_json
number_integer | 2147483648..9223372036854775807 | int64 | 0x12
number_unsigned | 0..2147483647 | int32 | 0x10
number_unsigned | 2147483648..9223372036854775807 | int64 | 0x12
number_unsigned | 9223372036854775808..18446744073709551615| -- | --
number_float | *any value* | double | 0x01
string | *any value* | string | 0x02
array | *any value* | document | 0x04
......@@ -18202,8 +18203,12 @@ class basic_json
@warning The mapping is **incomplete**, since only JSON-objects (and things
contained therein) can be serialized to BSON.
Also, integers larger than 9223372036854775807 cannot be serialized to BSON.
@pre The input `j` is required to be an object: `j.is_object() == true`
@throw out_of_range.407 if `j.is_number_unsigned() && j.get<std::uint64_t>() > 9223372036854775807`
@throw type_error.317 if `!j.is_object()`
@pre The input `j` is required to be an object: `j.is_object() == true`.
@note Any BSON output created via @ref to_bson can be successfully parsed
by @ref from_bson.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment