15 #ifndef RAPIDJSON_ERROR_ERROR_H_ 16 #define RAPIDJSON_ERROR_ERROR_H_ 18 #include "../rapidjson.h" 22 RAPIDJSON_DIAG_OFF(padded)
38 #ifndef RAPIDJSON_ERROR_CHARTYPE 39 #define RAPIDJSON_ERROR_CHARTYPE char 51 #ifndef RAPIDJSON_ERROR_STRING 52 #define RAPIDJSON_ERROR_STRING(x) x 116 size_t Offset()
const {
return offset_; }
123 bool operator==(
const ParseResult& that)
const {
return code_ == that.code_; }
124 bool operator==(
ParseErrorCode code)
const {
return code_ == code; }
155 #endif // RAPIDJSON_ERROR_ERROR_H_
Missing a comma or '}' after an object member.
#define RAPIDJSON_NAMESPACE_END
provide custom rapidjson namespace (closing expression)
Missing a comma or ']' after an array element.
ParseErrorCode Code() const
Get the error code.
Missing a name for object member.
Result of parsing (wraps ParseErrorCode)
#define RAPIDJSON_NAMESPACE_BEGIN
provide custom rapidjson namespace (opening expression)
Number too big to be stored in double.
void Set(ParseErrorCode code, size_t offset=0)
Update error code and offset.
ParseErrorCode
Error code of parsing.
Invalid escape character in string.
Invalid encoding in string.
ParseResult()
Default constructor, no error.
bool IsError() const
Whether the result is an error.
#define RAPIDJSON_ERROR_CHARTYPE
Character type of error messages.
Miss fraction part in number.
Incorrect hex digit after \u escape in string.
void Clear()
Reset error code.
The surrogate pair in string is invalid.
Missing a colon after a name of object member.
Missing a closing quotation mark in string.
ParseResult(ParseErrorCode code, size_t offset)
Constructor to set an error.
The document root must not follow by other values.
size_t Offset() const
Get the error offset, if IsError(), 0 otherwise.