Trait bitcoin_hashes::HashEngine [−][src]
pub trait HashEngine: Clone + Default { type MidState; const BLOCK_SIZE: usize; fn midstate(&self) -> Self::MidState; fn input(&mut self, data: &[u8]); fn n_bytes_hashed(&self) -> usize; }
A hashing engine which bytes can be serialized into
Associated Types
Loading content...Associated Constants
const BLOCK_SIZE: usize
[src]
Length of the hash’s internal block size, in bytes
Required methods
fn midstate(&self) -> Self::MidState
[src]
Outputs the midstate of the hash engine. This function should not be used directly unless you really know what you’re doing.
fn input(&mut self, data: &[u8])
[src]
Add data to the hash engine
fn n_bytes_hashed(&self) -> usize
[src]
Return the number of bytes already n_bytes_hashed(inputted)
Implementors
impl HashEngine for bitcoin_hashes::ripemd160::HashEngine
[src]
impl HashEngine for bitcoin_hashes::ripemd160::HashEngine
[src]impl HashEngine for bitcoin_hashes::sha1::HashEngine
[src]
impl HashEngine for bitcoin_hashes::sha1::HashEngine
[src]impl HashEngine for bitcoin_hashes::sha256::HashEngine
[src]
impl HashEngine for bitcoin_hashes::sha256::HashEngine
[src]impl HashEngine for bitcoin_hashes::sha512::HashEngine
[src]
impl HashEngine for bitcoin_hashes::sha512::HashEngine
[src]impl HashEngine for bitcoin_hashes::siphash24::HashEngine
[src]
impl HashEngine for bitcoin_hashes::siphash24::HashEngine
[src]impl<T: HashTrait> HashEngine for HmacEngine<T>
[src]
impl<T: HashTrait> HashEngine for HmacEngine<T>
[src]