libwolfram20
WAError.h
Go to the documentation of this file.
1
9#ifndef WAERROR_H
10#define WAERROR_H
11
12#include <string>
13
14#include <rapidxml/rapidxml_utils.hpp>
15
20class WAError {
21public:
26 WAError(const WAError &old) = default;
27 WAError(int code, const char *msg);
28 WAError(rapidxml::xml_node<>* error);
29
30 std::string getErrorMessage();
31 int getErrorCode();
32
33private:
41 int _code;
42 std::string _msg;
43
44 void parse(rapidxml::xml_node<>* error);
45};
46
47#endif // WAERROR_H
WAError(const WAError &old)=default
Copy constructor.
int getErrorCode()
It returns the error code.
Definition: WAError.cpp:45
std::string getErrorMessage()
It returns information about the error.
Definition: WAError.cpp:36
void parse(rapidxml::xml_node<> *error)
Parsing the input error.
Definition: WAError.cpp:55
int _code
The error code HTTP Status 501: This status is returned if a given input value cannot be interpreted ...
Definition: WAError.h:41
Wolfram API error element.
Definition: WAError.h:20
std::string _msg
A short message describing the error.
Definition: WAError.h:42