pub type ReadResourceFn = unsafe extern "C" fn(*const u8, usize, *mut *mut u8, *mut usize) -> i32;Expand description
Function signature for reading a resource by URI
Returns JSON: { "contents": [{ "uri", "mimeType?", "text?" | "blob?" }] }
§Parameters
uri_ptr: Resource URI as byte arrayuri_len: Length of URIresult_buf: Output pointer for result (allocated by plugin)result_len: Output capacity of result buffer
§Returns
- 0 on success
- Non-zero error code on failure