Skip to main content

ContentHasher

Trait ContentHasher 

Source
pub trait ContentHasher:
    'static
    + Send
    + Sync {
    const DIGEST_ALG: &'static str;

    // Required method
    fn hash(content: &[u8]) -> DigestHash;
}

Required Associated Constants§

Source

const DIGEST_ALG: &'static str

Required Methods§

Source

fn hash(content: &[u8]) -> DigestHash

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§