Function librbd_sys::rbd_read_iterate2
[−]
[src]
pub unsafe extern "C" fn rbd_read_iterate2(
image: rbd_image_t,
ofs: uint64_t,
len: uint64_t,
cb: Option<unsafe extern "C" fn(_: uint64_t, _: size_t, _: *const c_char, _: *mut c_void) -> c_int>,
arg: *mut c_void
) -> c_int
iterate read over an image Reads each region of the image and calls the callback. If the buffer pointer passed to the callback is NULL, the given extent is defined to be zeros (a hole). Normally the granularity for the callback is the image stripe size.
Arguments
image
image to readofs
offset to start fromlen
bytes of source image to covercb
callback for each region @returns 0 success, error otherwise