Struct winter_crypto::hashers::Blake3_256
source · pub struct Blake3_256<B: StarkField>(_);
Expand description
Implementation of the Hasher trait for BLAKE3 hash function with 256-bit output.
Trait Implementations
sourceimpl<B: Debug + StarkField> Debug for Blake3_256<B>
impl<B: Debug + StarkField> Debug for Blake3_256<B>
sourceimpl<B: StarkField> ElementHasher for Blake3_256<B>
impl<B: StarkField> ElementHasher for Blake3_256<B>
type BaseField = B
type BaseField = B
Specifies a base field for elements which can be hashed with this hasher.
sourcefn hash_elements<E: FieldElement<BaseField = Self::BaseField>>(
elements: &[E]
) -> Self::Digest
fn hash_elements<E: FieldElement<BaseField = Self::BaseField>>(
elements: &[E]
) -> Self::Digest
Returns a hash of the provided field elements.
sourceimpl<B: StarkField> Hasher for Blake3_256<B>
impl<B: StarkField> Hasher for Blake3_256<B>
type Digest = ByteDigest<32>
type Digest = ByteDigest<32>
Specifies a digest type returned by this hasher.
sourcefn merge(values: &[Self::Digest; 2]) -> Self::Digest
fn merge(values: &[Self::Digest; 2]) -> Self::Digest
Returns a hash of two digests. This method is intended for use in construction of
Merkle trees. Read more
sourcefn merge_with_int(seed: Self::Digest, value: u64) -> Self::Digest
fn merge_with_int(seed: Self::Digest, value: u64) -> Self::Digest
Returns hash(
seed
|| value
). This method is intended for use in PRNG and PoW contexts.sourceimpl<B: PartialEq + StarkField> PartialEq<Blake3_256<B>> for Blake3_256<B>
impl<B: PartialEq + StarkField> PartialEq<Blake3_256<B>> for Blake3_256<B>
sourcefn eq(&self, other: &Blake3_256<B>) -> bool
fn eq(&self, other: &Blake3_256<B>) -> bool
impl<B: Eq + StarkField> Eq for Blake3_256<B>
impl<B: StarkField> StructuralEq for Blake3_256<B>
impl<B: StarkField> StructuralPartialEq for Blake3_256<B>
Auto Trait Implementations
impl<B> RefUnwindSafe for Blake3_256<B>where
B: RefUnwindSafe,
impl<B> Send for Blake3_256<B>
impl<B> Sync for Blake3_256<B>
impl<B> Unpin for Blake3_256<B>where
B: Unpin,
impl<B> UnwindSafe for Blake3_256<B>where
B: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more