INNER CODE UNIT · Rust

ALL_PAGES

edwardkim/rhwp · bindings/Native/src/lib.rs:20

const ALL_PAGES: i32 = -1;

#[no_mangle]
pub extern "C" fn rhwp_export_text(
    input_path: *const c_char,
    output_dir: *const c_char,
    page: i32,
) -> *mut c_char {
    ffi_result(|| {
        let input_path = read_utf8(input_path, "input_path")?;
        let output_dir = read_utf8(output_dir, "output_dir")?;
        export_text_to_dir(
            Path::new(&input_path),
            Path::new(&output_dir),
            normalize_page(page)?,
        )
    })
}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…