MySQL 8.0.40
Source Code Documentation
event_reader_macros.h File Reference

Contains macros used by libbinlogevents deserialization. More...

Go to the source code of this file.

Namespaces

namespace  binary_log
 The namespace contains classes representing events that can occur in a replication stream.
 

Macros

#define READER_TRY_INITIALIZATION    if (!header()->get_is_valid()) BAPI_VOID_RETURN
 
#define READER_CATCH_ERROR
 
#define READER_CALL(func, ...)   reader().func(__VA_ARGS__)
 
#define READER_TRY_CALL(func, ...)
 
#define READER_SET(var, func, ...)
 
#define READER_TRY_SET(var, func, ...)
 
#define READER_THROW(message)
 
#define READER_ASSERT_POSITION(pos)   BAPI_ASSERT(READER_CALL(position) == pos)
 

Detailed Description

Contains macros used by libbinlogevents deserialization.

Macro Definition Documentation

◆ READER_ASSERT_POSITION

#define READER_ASSERT_POSITION (   pos)    BAPI_ASSERT(READER_CALL(position) == pos)

◆ READER_CALL

#define READER_CALL (   func,
  ... 
)    reader().func(__VA_ARGS__)

◆ READER_CATCH_ERROR

#define READER_CATCH_ERROR
Value:
event_reader_footer: \
header()->set_is_valid(READER_CALL(has_error) == false)
#define READER_CALL(func,...)
Definition: event_reader_macros.h:57

◆ READER_SET

#define READER_SET (   var,
  func,
  ... 
)
Value:
BAPI_PRINT("debug", ("Event_reader::SET %s", #var)); \
var = reader().func(__VA_ARGS__)
#define BAPI_PRINT(name, params)
Definition: wrapper_functions.h:63

◆ READER_THROW

#define READER_THROW (   message)
Value:
{ \
reader().set_error(message); \
goto event_reader_footer; \
}

◆ READER_TRY_CALL

#define READER_TRY_CALL (   func,
  ... 
)
Value:
READER_CALL(func, __VA_ARGS__); \
if (reader().get_error()) goto event_reader_footer

◆ READER_TRY_INITIALIZATION

#define READER_TRY_INITIALIZATION    if (!header()->get_is_valid()) BAPI_VOID_RETURN

◆ READER_TRY_SET

#define READER_TRY_SET (   var,
  func,
  ... 
)
Value:
READER_SET(var, func, __VA_ARGS__); \
if (reader().get_error()) goto event_reader_footer
#define READER_SET(var, func,...)
Definition: event_reader_macros.h:69