Img2Num C
API Documentation
Loading...
Searching...
No Matches
img2num_error_t.cpp File Reference
#include "cimg2num/img2num_error_t.h"
#include "img2num/Error.h"
#include <cstring>
+ Include dependency graph for img2num_error_t.cpp:

Go to the source code of this file.

Functions

img2num_error_t img2num_get_last_error ()
 
const char * img2num_get_last_error_message ()
 
void img2num_clear_last_error ()
 

Function Documentation

◆ img2num_clear_last_error()

void img2num_clear_last_error ( )

Definition at line 38 of file img2num_error_t.cpp.

38 {
39 img2num::clear_last_error();
40}

◆ img2num_get_last_error()

img2num_error_t img2num_get_last_error ( )

Definition at line 27 of file img2num_error_t.cpp.

27 {
28 const img2num::Error cpp_err {img2num::get_last_error()};
29 return cpp_error_to_c_error(cpp_err);
30}

◆ img2num_get_last_error_message()

const char * img2num_get_last_error_message ( )

Definition at line 32 of file img2num_error_t.cpp.

32 {
33 static thread_local std::string msg;
34 msg = img2num::get_last_error_message();
35 return msg.c_str();
36}