XRTraits C++ OpenXR Utilities
Public Member Functions | List of all members
xrtraits::exceptions::xr_runtime_error Struct Reference

#include <BaseExceptions.h>

Inheritance diagram for xrtraits::exceptions::xr_runtime_error:
Inheritance graph
[legend]
Collaboration diagram for xrtraits::exceptions::xr_runtime_error:
Collaboration graph
[legend]

Public Member Functions

 xr_runtime_error (std::string &&what, XrResult err)
 
 xr_runtime_error (std::string const &what, XrResult err)
 
 xr_runtime_error (std::string &&what)
 
 xr_runtime_error (XrResult err, const char *condition, const char *msg)
 
- Public Member Functions inherited from xrtraits::exceptions::xr_exception
const char * what () const noexcept override
 
bool hasResult () const noexcept
 
XrResult result () const noexcept
 

Additional Inherited Members

- Protected Member Functions inherited from xrtraits::exceptions::xr_exception
 xr_exception (std::string &&what)
 
 xr_exception (std::string const &what, XrResult err)
 
 xr_exception (std::string &&what, XrResult err)
 

Detailed Description

Base class for OpenXR-related exceptions explicitly thrown by this library's code.

Conceptually related to std::runtime_error, though not deriving from it. May specify an associated/recommended XrResult code.

Note
Prefer instantiating derived classes, if a suitable one exists, instead of instantiating this class directly.

Constructor & Destructor Documentation

◆ xr_runtime_error() [1/4]

xrtraits::exceptions::xr_runtime_error::xr_runtime_error ( std::string &&  what,
XrResult  err 
)

Constructor taking a "what" string as well as an XrResult.

◆ xr_runtime_error() [2/4]

xrtraits::exceptions::xr_runtime_error::xr_runtime_error ( std::string const &  what,
XrResult  err 
)

Constructor taking a "what" string as well as an XrResult.

◆ xr_runtime_error() [3/4]

xrtraits::exceptions::xr_runtime_error::xr_runtime_error ( std::string &&  what)

Constructor taking a "what" string

◆ xr_runtime_error() [4/4]

xrtraits::exceptions::xr_runtime_error::xr_runtime_error ( XrResult  err,
const char *  condition,
const char *  msg 
)

Constructor taking an XrResult (which will be included in the "what" string), a condition, and a message.

Primarily used by throwIfNotSucceeded() and throwIfNotUnqualifiedSuccess()


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