1#ifndef JSON_ERROR_HANDLER_INCLUDED 
    2#define JSON_ERROR_HANDLER_INCLUDED 
   35    std::function<void(
const char *parse_err, 
size_t err_offset)>;
 
   38    std::function<void(
const char *target_type, 
int error_code)>;
 
   82  void operator()(
const char *parse_err, 
size_t err_offset) 
const;
 
  115  void operator()(
const char *target_type, 
int error_code) 
const;
 
  128  void operator()(
const char *target_type, 
int error_code) 
const;
 
Callback function that checks if MYSQL_TIME_STATUS contains a deprecation warning.
Definition: json_error_handler.h:138
 
void operator()(MYSQL_TIME_STATUS &status) const
Definition: json_error_handler.cc:86
 
Callback function called when a coercion error occurs.
Definition: json_error_handler.h:112
 
const char * m_msgnam
The name of the field/expression being coerced to be used in error message if conversion failed.
Definition: json_error_handler.h:120
 
void operator()(const char *target_type, int error_code) const
Definition: json_error_handler.cc:68
 
JsonCoercionErrorHandler(const char *msgnam)
Definition: json_error_handler.h:114
 
Callback function called when a coercion error occurs.
Definition: json_error_handler.h:125
 
void operator()(const char *target_type, int error_code) const
Definition: json_error_handler.cc:74
 
JsonCoercionWarnHandler(const char *msgnam)
Definition: json_error_handler.h:127
 
const char * m_msgnam
The name of the field/expression being coerced to be used in error message if conversion failed.
Definition: json_error_handler.h:133
 
Definition: json_error_handler.h:77
 
const int m_arg_idx
Definition: json_error_handler.h:86
 
JsonParseDefaultErrorHandler(const char *func_name, int arg_idx)
Definition: json_error_handler.h:79
 
void operator()(const char *parse_err, size_t err_offset) const
Definition: json_error_handler.cc:35
 
const char * m_func_name
Definition: json_error_handler.h:85
 
Error handler to be used when serializing JSON binary values in server code.
Definition: json_error_handler.h:96
 
void TooDeep() const override
Called when a JSON document has more nesting levels than supported.
Definition: json_error_handler.cc:51
 
const THD * m_thd
Definition: json_error_handler.h:107
 
void KeyTooBig() const override
Called when a JSON object contains a member with a name that is longer than supported by the JSON bin...
Definition: json_error_handler.cc:43
 
void InternalError(const char *message) const override
Called when an internal error occurs.
Definition: json_error_handler.cc:59
 
void ValueTooBig() const override
Called when a JSON document is too big to be stored in the JSON binary format.
Definition: json_error_handler.cc:47
 
bool CheckStack() const override
Check if the stack is about to be exhausted, and report the error.
Definition: json_error_handler.cc:64
 
void InvalidJson() const override
Called when an invalid JSON value is encountered.
Definition: json_error_handler.cc:55
 
JsonSerializationDefaultErrorHandler(const THD *thd)
Definition: json_error_handler.h:98
 
Error handler for the functions that serialize a JSON value in the JSON binary storage format.
Definition: json_error_handler.h:49
 
virtual void InvalidJson() const =0
Called when an invalid JSON value is encountered.
 
virtual void ValueTooBig() const =0
Called when a JSON document is too big to be stored in the JSON binary format.
 
virtual bool CheckStack() const =0
Check if the stack is about to be exhausted, and report the error.
 
virtual void KeyTooBig() const =0
Called when a JSON object contains a member with a name that is longer than supported by the JSON bin...
 
virtual ~JsonSerializationErrorHandler()=default
 
virtual void InternalError(const char *message) const =0
Called when an internal error occurs.
 
virtual void TooDeep() const =0
Called when a JSON document has more nesting levels than supported.
 
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:36
 
std::function< void(MYSQL_TIME_STATUS &status)> JsonCoercionDeprecatedHandler
Definition: json_error_handler.h:40
 
std::function< void(const char *target_type, int error_code)> JsonCoercionHandler
Definition: json_error_handler.h:38
 
void JsonDepthErrorHandler()
Definition: json_error_handler.cc:41
 
std::function< void()> JsonErrorHandler
Definition: json_error_handler.h:36
 
std::function< void(const char *parse_err, size_t err_offset)> JsonParseErrorHandler
Definition: json_error_handler.h:35
 
required uint32 status
Definition: replication_asynchronous_connection_failover.proto:61
 
Definition: m_ctype.h:423
 
Structure to return status from str_to_datetime(), str_to_time(), number_to_datetime(),...
Definition: my_time.h:170