Skip to main content

obj_iter_next

Function obj_iter_next 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn obj_iter_next( iter: *mut obj_iter_t, out_id: *mut u64, out_payload: *mut *mut u8, out_payload_len: *mut usize, ) -> obj_error_t
Expand description

Step the iterator. On OBJ_OK the caller owns *out_payload (length *out_payload_len) and MUST free it with obj_free_buffer. Returns OBJ_ERR_NOT_FOUND at end-of- iteration; a real engine failure surfaces as the corresponding error code.

ยงSafety

  • iter must be a live iterator handle.
  • out_id, out_payload, out_payload_len must be writable.