JSON Voorhees
Killer JSON for C++
Loading...
Searching...
No Matches
jsonv::extraction_error::problem Class Reference

Description of a single problem with extraction. More...

#include <jsonv/serialization.hpp>

Public Member Functions

 problem (jsonv::path path, std::exception_ptr cause) noexcept
 Create a problem with a message extracted from cause.
 
const jsonv::pathpath () const noexcept
 The path this problem was encountered at.
 
const std::string & message () const noexcept
 Human-readable details about the encountered problem.
 
const std::exception_ptr & nested_ptr () const noexcept
 If there was an exception that caused this problem, extra details can be found in the nested exception.
 
 problem (jsonv::path path, std::string message, std::exception_ptr cause) noexcept
 
 problem (jsonv::path path, std::string message) noexcept
 

Detailed Description

Description of a single problem with extraction.

Definition at line 74 of file serialization.hpp.

Constructor & Destructor Documentation

◆ problem() [1/2]

jsonv::extraction_error::problem::problem ( jsonv::path  path,
std::string  message,
std::exception_ptr  cause 
)
explicitnoexcept

Create a problem for the given path, message, and optional cause.

◆ problem() [2/2]

jsonv::extraction_error::problem::problem ( jsonv::path  path,
std::exception_ptr  cause 
)
explicitnoexcept

Create a problem with a message extracted from cause.

Parameters
causeThe underlying cause of this problem to extract the message from. If the exception backing cause is not derived from std::exception, a message about unknown exception will be used instead.

Member Function Documentation

◆ message()

const std::string & jsonv::extraction_error::problem::message ( ) const
inlinenoexcept

Human-readable details about the encountered problem.

Definition at line 97 of file serialization.hpp.

◆ nested_ptr()

const std::exception_ptr & jsonv::extraction_error::problem::nested_ptr ( ) const
inlinenoexcept

If there was an exception that caused this problem, extra details can be found in the nested exception.

This can be nullptr if there was no underlying cause.

Definition at line 104 of file serialization.hpp.

◆ path()

const jsonv::path & jsonv::extraction_error::problem::path ( ) const
inlinenoexcept

The path this problem was encountered at.

Definition at line 91 of file serialization.hpp.


The documentation for this class was generated from the following file: