#include <sstream>
#include <string>
|
template<typename Last > |
void | VW::experimental::report_error (std::ostringstream &os, const Last &last) |
| Ends recursion of report_error variadic template with the Last argument. More...
|
|
template<typename First , typename... Rest> |
void | VW::experimental::report_error (std::ostringstream &os, const First &first, const Rest &... rest) |
| Begins recursion of report_error variadic template with ostringstream to serialize error information. More...
|
|
template<typename... All> |
int | VW::experimental::report_error (api_status *status, int scode, const All &... all) |
| The main report_error template used to serialize error into api_status The method most end users will use with a status code and a number of objects to be serialised into an api_status. More...
|
|
template<typename T > |
VW::experimental::status_builder & | VW::experimental::operator<< (VW::experimental::status_builder &sb, const T &val) |
| left shift operator to serialize types into stringstream held in status_builder More...
|
|
int | VW::experimental::report_error (status_builder &sb) |
| Terminates recursion of report_error. More...
|
|
template<typename Last > |
int | VW::experimental::report_error (status_builder &sb, const Last &last) |
| report_error that takes the final paramter More...
|
|
template<typename First , typename... Rest> |
int | VW::experimental::report_error (status_builder &sb, const First &first, const Rest &... rest) |
| variadic template report_error that takes a list of parameters More...
|
|
◆ RETURN_ERROR
#define RETURN_ERROR |
( |
|
status, |
|
|
|
code, |
|
|
|
... |
|
) |
| |
Value: do { \
if (status != nullptr) \
{ \
sb << VW::experimental::error_code::code##_s; \
return report_error(sb); \
} \
return VW::experimental::error_code::code; \
} while (0);
Helper class used in report_error template funcstions to return status from API calls.
Definition: api_status.h:69
Error reporting macro for just returning an error code.
◆ RETURN_ERROR_ARG
#define RETURN_ERROR_ARG |
( |
|
status, |
|
|
|
code, |
|
|
|
... |
|
) |
| |
Value: do { \
if (status != nullptr) \
{ \
sb << VW::experimental::error_code::code##_s; \
return report_error(sb, __VA_ARGS__); \
} \
return VW::experimental::error_code::code; \
} while (0);
Error reporting macro that takes a list of parameters.
◆ RETURN_ERROR_LS
#define RETURN_ERROR_LS |
( |
|
status, |
|
|
|
code |
|
) |
| |
Value:
return sb << VW::experimental::error_code::code##_s
Error reporting macro used with left shift operator.
◆ RETURN_IF_FAIL
#define RETURN_IF_FAIL |
( |
|
x | ) |
|
Value: do { \
int retval__LINE__ = (x); \
if (retval__LINE__ != 0) { return retval__LINE__; } \
} while (0)
Error reporting macro to test and return on error.