agde::hash_check

Struct ResponseHasher

source
pub struct ResponseHasher(/* private fields */);
Expand description

A hash builder for adding the hashed signature of a resource. Should be created, written to and the added when all the data is written.

Implementations§

source§

impl ResponseHasher

source

pub fn new() -> Self

Creates a new, empty hasher.

Add data using Self::write.

source

pub fn write(&mut self, bytes: &[u8])

Write data from resource to the internal hasher.

After all the data for one resource is written, call ResponseBuilder::insert.

source

pub fn finish(self) -> ResponseHash

Digest this hash.

Trait Implementations§