Struct simd_adler32::Adler32
source · pub struct Adler32 { /* private fields */ }
Expand description
An adler32 hash generator type.
Implementations§
source§impl Adler32
impl Adler32
sourcepub fn new() -> Self
pub fn new() -> Self
Constructs a new Adler32
.
Potential overhead here due to runtime feature detection although in testing on 100k and 10k random byte arrays it was not really noticeable.
§Examples
use simd_adler32::Adler32;
let mut adler = Adler32::new();
sourcepub fn from_checksum(checksum: u32) -> Self
pub fn from_checksum(checksum: u32) -> Self
Constructs a new Adler32
using existing checksum.
Potential overhead here due to runtime feature detection although in testing on 100k and 10k random byte arrays it was not really noticeable.
§Examples
use simd_adler32::Adler32;
let mut adler = Adler32::from_checksum(0xdeadbeaf);
sourcepub fn write(&mut self, data: &[u8])
pub fn write(&mut self, data: &[u8])
Computes hash for supplied data and stores results in internal state.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Adler32
impl RefUnwindSafe for Adler32
impl Send for Adler32
impl Sync for Adler32
impl Unpin for Adler32
impl UnwindSafe for Adler32
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)