Type Alias lmdb_master_sys::MDB_rel_func
source · pub type MDB_rel_func = Option<unsafe extern "C" fn(item: *mut MDB_val, oldptr: *mut c_void, newptr: *mut c_void, relctx: *mut c_void)>;
Expand description
A callback function used to relocate a position-dependent data item in a fixed-address database.
The newptr gives the item’s desired address in the memory map, and oldptr gives its previous address. The item’s actual data resides at the address in item. This callback is expected to walk through the fields of the record in item and modify any values based at the oldptr address to be relative to the newptr address.
§Arguments
item
(direction in, out) - The item that is to be relocated.oldptr
(direction in) - The previous address.newptr
(direction in) - The new address to relocate to.relctx
(direction in) - An application-provided context, set by #mdb_set_relctx(). This feature is currently unimplemented.
Aliased Type§
enum MDB_rel_func {
None,
Some(unsafe extern "C" fn(_: *mut MDB_val, _: *mut c_void, _: *mut c_void, _: *mut c_void)),
}