Trait mina_merkle::MerkleHasher
source · [−]pub trait MerkleHasher {
type Item;
type Hash;
fn hash(item: &Self::Item, metadata: MerkleTreeNodeMetadata) -> Self::Hash;
}
Expand description
Trait for implementing binary merkle tree hasher
Required Associated Types
Type that MerkleHasher calculates hash from
Required Methods
sourcefn hash(item: &Self::Item, metadata: MerkleTreeNodeMetadata) -> Self::Hash
fn hash(item: &Self::Item, metadata: MerkleTreeNodeMetadata) -> Self::Hash
Calculates hash from an item and its associated metadata