adler32_checksum_rs

Crates.ioadler32_checksum_rs
lib.rsadler32_checksum_rs
version0.1.0
sourcesrc
created_at2023-03-07 14:27:28.348945
updated_at2023-03-07 14:27:28.348945
descriptionAdler32 checksum
homepage
repositoryhttps://github.com/Derghust/adler32_checksum_rs
max_upload_size
id803620
size13,249
Damien Clément (Derghust)

documentation

README

adler32_checksum_rs

License Issues CI Activity Version

Adler 32 checksum algorithm written for rust.

Wikipedia

How to use

Sequel

fn adler32_checksum_blocking(init: [u8; 8], data: Vec<u8>) -> Adler32Result {
    let adler = Adler32::new(init);
    adler.adler32_checksum(data);
}

Batch

Synchronously

fn adler32_checksum_blocking(init: [u8; 8], data: Vec<Vec<u8>>) -> Vec<Adler32Result> {
    let adler = Adler32::new(init);
    data
    .iter()
    .map(|hash| {
        adler.adler32_checksum(hash);
    })
    .collect();
}

Asynchronously

fn adler32_checksum_parallel(init: [u8; 8], data: Vec<Vec<u8>>) -> Vec<Adler32Result> {
    Adler32Builder::new(Adler32::new(init))
        .push_vec(data)
        .finalize();
}
Commit count: 6

cargo fmt