pub struct BinaryMerkleTreeScheme<T, H, C> { /* private fields */ }
Implementations§
Source§impl<T, H, C> BinaryMerkleTreeScheme<T, H, C>
impl<T, H, C> BinaryMerkleTreeScheme<T, H, C>
pub fn compression(&self) -> &C
Source§impl<T, H, C> BinaryMerkleTreeScheme<T, H, C>
impl<T, H, C> BinaryMerkleTreeScheme<T, H, C>
Trait Implementations§
Source§impl<F, H, C> MerkleTreeScheme<F> for BinaryMerkleTreeScheme<F, H, C>
impl<F, H, C> MerkleTreeScheme<F> for BinaryMerkleTreeScheme<F, H, C>
Source§fn optimal_verify_layer(&self, n_queries: usize, tree_depth: usize) -> usize
fn optimal_verify_layer(&self, n_queries: usize, tree_depth: usize) -> usize
This layer allows minimizing the proof size.
type Digest = GenericArray<u8, <H as OutputSizeUser>::OutputSize>
Source§fn proof_size(
&self,
len: usize,
n_queries: usize,
layer_depth: usize,
) -> Result<usize, Error>
fn proof_size( &self, len: usize, n_queries: usize, layer_depth: usize, ) -> Result<usize, Error>
Returns the total byte-size of a proof for multiple opening queries. Read more
Source§fn verify_vector(
&self,
root: &Self::Digest,
data: &[F],
batch_size: usize,
) -> Result<(), Error>
fn verify_vector( &self, root: &Self::Digest, data: &[F], batch_size: usize, ) -> Result<(), Error>
Verify the opening of the full vector.
Auto Trait Implementations§
impl<T, H, C> Freeze for BinaryMerkleTreeScheme<T, H, C>where
C: Freeze,
impl<T, H, C> RefUnwindSafe for BinaryMerkleTreeScheme<T, H, C>where
C: RefUnwindSafe,
impl<T, H, C> Send for BinaryMerkleTreeScheme<T, H, C>where
C: Send,
impl<T, H, C> Sync for BinaryMerkleTreeScheme<T, H, C>where
C: Sync,
impl<T, H, C> Unpin for BinaryMerkleTreeScheme<T, H, C>where
C: Unpin,
impl<T, H, C> UnwindSafe for BinaryMerkleTreeScheme<T, H, C>where
C: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more