File: write_result.md

package info (click to toggle)
jsoncons 1.5.0-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 18,276 kB
  • sloc: cpp: 143,266; sh: 34; makefile: 8
file content (29 lines) | stat: -rw-r--r-- 877 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
### jsoncons::write_result

```cpp
#include <jsoncons/ser_util.hpp>

using write_result = jsoncons::expected<void,std::error_code>;
```

#### Member types

Member type                         |Definition
------------------------------------|------------------------------
`value_type`|void
`error_type`|[std::error_code](https://en.cppreference.com/w/cpp/error/error_code.html)

#### Accessors  

    constexpr operator bool() const noexcept;  
    constexpr bool has_value() const noexcept;  
Checks whether the result contains an unexpected value

    constexpr read_error& error() & noexcept;  
    constexpr const read_error& error() const & noexcept;  
    constexpr read_error&& error() && noexcept;  
    constexpr const read_error&& error() const && noexcept;  
Returns the unexpected value [std::error_code](https://en.cppreference.com/w/cpp/error/error_code.html)