Class passed to an error. More...
#include <core.hpp>
Public Member Functions | |
Exception () | |
Exception (int _code, const String &_err, const String &_func, const String &_file, int _line) | |
virtual | ~Exception () throw () |
virtual const char * | what () const CV_OVERRIDE throw () |
void | formatMessage () |
Public Member Functions inherited from std::exception | |
T | what (T... args) |
T | ~exception (T... args) |
T | operator= (T... args) |
T | exception (T... args) |
Public Attributes | |
String | msg |
the formatted error message More... | |
int | code |
error code More... | |
String | err |
error description More... | |
String | func |
function name. Available only when the compiler supports getting it More... | |
String | file |
source file name where the error has occurred More... | |
int | line |
line number in the source file where the error has occurred More... | |
Class passed to an error.
This class encapsulates all or almost all necessary information about the error happened in the program. The exception is usually constructed and thrown implicitly via CV_Error and CV_Error_ macros.
cv::Exception::Exception | ( | ) |
Default constructor
cv::Exception::Exception | ( | int | _code, |
const String & | _err, | ||
const String & | _func, | ||
const String & | _file, | ||
int | _line | ||
) |
Full constructor. Normally the constructor is not called explicitly. Instead, the macros CV_Error(), CV_Error_() and CV_Assert() are used.
|
virtual |
void cv::Exception::formatMessage | ( | ) |
|
virtual |
int cv::Exception::code |
error code
String cv::Exception::err |
error description
String cv::Exception::file |
source file name where the error has occurred
String cv::Exception::func |
function name. Available only when the compiler supports getting it
int cv::Exception::line |
line number in the source file where the error has occurred
String cv::Exception::msg |
the formatted error message