json_exception

Module: Exceptions

The base class for the JSON and depicts exceptions that are thrown when there is a JSON parsing error. This means an error in serializing or deserializing JSON string or object.

#include <exception.h>

Inherits from dolbyio::comms::exception, exception

Public Functions

Name
const std::string &path() const
The accessor that returns the full path of the exception.
json_exception(std::string && description, std::string && path)
The constructor that takes a description of the exception.
const std::string &desc() const
The accessor that returns a description of the exception string.

Protected Attributes

Name
std::stringpath_
std::stringdescription_

Additional inherited members

Public Functions inherited from dolbyio::comms::exception

Name
~exception() =default
const char *what() const override
Overrides to std::exception that returns a description of the exception.
exception(const std::string & description)
The constructor that takes the description of the exception.

Protected Attributes inherited from dolbyio::comms::exception

Name
std::stringfulldescription
class dolbyio::comms::json_exception;

Public Functions Documentation

function path

inline const std::string & path() const

The accessor that returns the full path of the exception.

Return: A string that contains a full path of the exception.

function json_exception

inline json_exception(
    std::string && description,
    std::string && path
)

The constructor that takes a description of the exception.

Parameters:

  • description The description of the exception.
  • path JSON object path

function desc

inline const std::string & desc() const

The accessor that returns a description of the exception string.

Return: A string that contains a description of the exception.

Protected Attributes Documentation

variable path_

std::string path_;

variable description_

std::string description_;


Did this page help you?