Move operator<< and operator>> doc pages out of basic_json/

This commit is contained in:
Florian Albrechtskirchinger 2022-07-24 08:19:43 +02:00
parent 7aa4b72ab3
commit 5f59a20e0c
No known key found for this signature in database
GPG Key ID: 19618CE9B2D4BE6D
7 changed files with 19 additions and 16 deletions

View File

@ -96,7 +96,7 @@ Linear in the length of the input. The parser is a predictive LL(1) parser.
## See also
- [parse](parse.md) - deserialize from a compatible input
- [operator>>](operator_gtgt.md) - deserialize from stream
- [operator>>](../operator_gtgt.md) - deserialize from stream
## Version history

View File

@ -283,8 +283,8 @@ Access to the JSON value
## Non-member functions
- [**operator<<(std::ostream&)**](operator_ltlt.md) - serialize to stream
- [**operator>>(std::istream&)**](operator_gtgt.md) - deserialize from stream
- [**operator<<(std::ostream&)**](../operator_ltlt.md) - serialize to stream
- [**operator>>(std::istream&)**](../operator_gtgt.md) - deserialize from stream
- [**to_string**](to_string.md) - user-defined `to_string` function for JSON values
## Literals

View File

@ -196,7 +196,7 @@ super-linear complexity.
## See also
- [accept](accept.md) - check if the input is valid JSON
- [operator>>](operator_gtgt.md) - deserialize from stream
- [operator>>](../operator_gtgt.md) - deserialize from stream
## Version history

View File

@ -20,10 +20,10 @@ the stream `i`
## Exceptions
- Throws [`parse_error.101`](../../home/exceptions.md#jsonexceptionparse_error101) in case of an unexpected token.
- Throws [`parse_error.102`](../../home/exceptions.md#jsonexceptionparse_error102) if to_unicode fails or surrogate
- Throws [`parse_error.101`](../home/exceptions.md#jsonexceptionparse_error101) in case of an unexpected token.
- Throws [`parse_error.102`](../home/exceptions.md#jsonexceptionparse_error102) if to_unicode fails or surrogate
error.
- Throws [`parse_error.103`](../../home/exceptions.md#jsonexceptionparse_error103) if to_unicode fails.
- Throws [`parse_error.103`](../home/exceptions.md#jsonexceptionparse_error103) if to_unicode fails.
## Complexity
@ -57,8 +57,8 @@ A UTF-8 byte order mark is silently ignored.
## See also
- [accept](accept.md) - check if the input is valid JSON
- [parse](parse.md) - deserialize from a compatible input
- [accept](basic_json/accept.md) - check if the input is valid JSON
- [parse](basic_json/parse.md) - deserialize from a compatible input
## Version history

View File

@ -7,7 +7,7 @@ std::ostream& operator<<(std::ostream& o, const json_pointer& ptr); // (2)
```
1. Serialize the given JSON value `j` to the output stream `o`. The JSON value will be serialized using the
[`dump`](dump.md) member function.
[`dump`](basic_json/dump.md) member function.
- The indentation of the output can be controlled with the member variable `width` of the output stream `o`. For
instance, using the manipulator `std::setw(4)` on `o` sets the indentation level to `4` and the serialization
result is the same as calling `dump(4)`.
@ -15,7 +15,7 @@ std::ostream& operator<<(std::ostream& o, const json_pointer& ptr); // (2)
For instance, the manipulator `std::setfill('\\t')` sets indentation to use a tab character rather than the
default space character.
2. Write a string representation of the given JSON pointer `ptr` to the output stream `o`. The string representation is
obtained using the [`to_string`](../json_pointer/to_string.md) member function.
obtained using the [`to_string`](json_pointer/to_string.md) member function.
## Parameters
@ -34,8 +34,8 @@ the stream `o`
## Exceptions
1. Throws [`type_error.316`](../../home/exceptions.md#jsonexceptiontype_error316) if a string stored inside the JSON
value is not UTF-8 encoded. Note that unlike the [`dump`](dump.md) member functions, no `error_handler` can be set.
1. Throws [`type_error.316`](../home/exceptions.md#jsonexceptiontype_error316) if a string stored inside the JSON
value is not UTF-8 encoded. Note that unlike the [`dump`](basic_json/dump.md) member functions, no `error_handler` can be set.
2. None.
## Complexity

View File

@ -36,7 +36,7 @@ JSON Lines input with more than one value is treated as invalid JSON by the [`pa
!!! warning "Note"
Using [`operator>>`](../../api/basic_json/operator_gtgt.md) like
Using [`operator>>`](../../api/operator_gtgt.md) like
```cpp
json j;

View File

@ -162,8 +162,6 @@ nav:
- 'operator<=': api/basic_json/operator_le.md
- 'operator>=': api/basic_json/operator_ge.md
- 'operator<=>': api/basic_json/operator_spaceship.md
- 'operator<<': api/basic_json/operator_ltlt.md
- 'operator>>': api/basic_json/operator_gtgt.md
- 'operator""_json': api/basic_json/operator_literal_json.md
- 'operator""_json_pointer': api/basic_json/operator_literal_json_pointer.md
- 'out_of_range': api/basic_json/out_of_range.md
@ -235,6 +233,9 @@ nav:
- 'start_array': api/json_sax/start_array.md
- 'start_object': api/json_sax/start_object.md
- 'string': api/json_sax/string.md
- 'operator<<(basic_json)': api/operator_ltlt.md
- 'operator<<(json_pointer)': api/operator_ltlt.md
- 'operator>>(basic_json)': api/operator_gtgt.md
- 'ordered_json': api/ordered_json.md
- 'ordered_map': api/ordered_map.md
- macros:
@ -326,6 +327,8 @@ plugins:
- git-revision-date-localized
- redirects:
redirect_maps:
'api/basic_json/operator_gtgt.md': api/operator_gtgt.md
'api/basic_json/operator_ltlt.md': api/operator_ltlt.md
extra_css:
- css/custom.css