Type Alias mysqlclient_sys::MYSQL_PLUGIN_VIO

source ·
pub type MYSQL_PLUGIN_VIO = st_plugin_vio;

Aliased Type§

struct MYSQL_PLUGIN_VIO {
    pub read_packet: Option<unsafe extern "C" fn(_: *mut st_plugin_vio, _: *mut *mut u8) -> i32>,
    pub write_packet: Option<unsafe extern "C" fn(_: *mut st_plugin_vio, _: *const u8, _: i32) -> i32>,
    pub info: Option<unsafe extern "C" fn(_: *mut st_plugin_vio, _: *mut st_plugin_vio_info)>,
}

Fields§

§read_packet: Option<unsafe extern "C" fn(_: *mut st_plugin_vio, _: *mut *mut u8) -> i32>

Plugin provides a pointer reference and this function sets it to the contents of any incoming packet. Returns the packet length, or -1 if the plugin should terminate.

§write_packet: Option<unsafe extern "C" fn(_: *mut st_plugin_vio, _: *const u8, _: i32) -> i32>

Plugin provides a buffer with data and the length and this function sends it as a packet. Returns 0 on success, 1 on failure.

§info: Option<unsafe extern "C" fn(_: *mut st_plugin_vio, _: *mut st_plugin_vio_info)>

Fills in a st_plugin_vio_info structure, providing the information about the connection.