invalid_token_exception

Module: SDK Event Types

The class that describes the rejected REST API requests caused by an invalid access token. The user can also set a listener for this exception object using sdk::add_event_handler. In such a case, the event will be emitted whenever a signaling error occurs.

#include <exception.h>

Inherits from dolbyio::comms::restapi_exception, dolbyio::comms::io_exception, dolbyio::comms::exception, exception

Public Functions

Name
invalid_token_exception(int http_code, int rest_code, const std::string & err_reason, const std::string & err_description)
The constructor that takes the error codes, reasons, and descriptions of the error that is in the server response.

Additional inherited members

Public Functions inherited from dolbyio::comms::restapi_exception

Name
restapi_exception(int http_code, int rest_code, const std::string & err_reason, const std::string & err_description)
The constructor that takes the error code, reason, and description of the error from a server response.
intrest_code() const
The accessor for the REST code of the exception.
const std::string &reason() const
The accessor for the reason of the error.
inthttp_code() const
The accessor for the HTTP code of the exception.
const std::string &description() const
The accessor for the error description.

Public Functions inherited from dolbyio::comms::io_exception

Name
io_exception(const std::string & description)
The constructor that takes the description of the exception.

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::invalid_token_exception;

Public Functions Documentation

function invalid_token_exception

inline invalid_token_exception(
    int http_code,
    int rest_code,
    const std::string & err_reason,
    const std::string & err_description
)

The constructor that takes the error codes, reasons, and descriptions of the error that is in the server response.

Parameters:

  • http_code The HTTP code.
  • rest_code The REST API code.
  • err_reason The reason for the error.
  • err_description The error description.


Did this page help you?