Type Alias alpm_sys::alpm_cb_fetch

source ·
pub type alpm_cb_fetch = Option<unsafe extern "C" fn(ctx: *mut c_void, url: *const c_char, localpath: *const c_char, force: c_int) -> c_int>;
Expand description

A callback for downloading files @param ctx user-provided context @param url the URL of the file to be downloaded @param localpath the directory to which the file should be downloaded @param force whether to force an update, even if the file is the same @return 0 on success, 1 if the file exists and is identical, -1 on error.

Aliased Type§

enum alpm_cb_fetch {
    None,
    Some(unsafe extern "C" fn(_: *mut c_void, _: *const i8, _: *const i8, _: i32) -> i32),
}

Variants§

§1.0.0

None

No value.

§1.0.0

Some(unsafe extern "C" fn(_: *mut c_void, _: *const i8, _: *const i8, _: i32) -> i32)

Some value of type T.