[][src]Struct iocutil::hasher::Hasher

pub struct Hasher { /* fields omitted */ }

Hash calculator

Methods

impl Hasher[src]

pub fn new() -> Self[src]

create new hasher

pub fn digests(&mut self) -> ContentHash[src]

get hash digests

Example

use iocutil::prelude::*;

let mut hasher = Hasher::default();
let mut f = std::fs::File::open("./Cargo.toml").expect("failed to open Cargo.toml");
std::io::copy(&mut f, &mut hasher).unwrap();
println!("{:?}", hasher.digests());

Trait Implementations

impl Default for Hasher[src]

impl Write for Hasher[src]

Auto Trait Implementations

impl Send for Hasher

impl Sync for Hasher

impl Unpin for Hasher

impl UnwindSafe for Hasher

impl RefUnwindSafe for Hasher

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<W> WriteBytesExt for W where
    W: Write + ?Sized

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Err = <U as TryFrom<T>>::Err