pub struct PhasedAsScheme<P>(/* private fields */);Expand description
An adapter that exposes a PhasedScheme through the Scheme trait.
In most cases, this is not the most optimal way to use a PhasedScheme,
or to expose a PhasedScheme as a Scheme for that matter. However,
it can be useful for testing or for usecases where the phased scheme
cannot be used directly.
Trait Implementations§
Source§impl<P: Clone> Clone for PhasedAsScheme<P>
impl<P: Clone> Clone for PhasedAsScheme<P>
Source§fn clone(&self) -> PhasedAsScheme<P>
fn clone(&self) -> PhasedAsScheme<P>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<P: Debug> Debug for PhasedAsScheme<P>
impl<P: Debug> Debug for PhasedAsScheme<P>
Source§impl<P: Default> Default for PhasedAsScheme<P>
impl<P: Default> Default for PhasedAsScheme<P>
Source§fn default() -> PhasedAsScheme<P>
fn default() -> PhasedAsScheme<P>
Returns the “default value” for a type. Read more
Source§impl<P: PhasedScheme> Scheme for PhasedAsScheme<P>
Available on neither commonware_stability_BETA nor commonware_stability_GAMMA nor commonware_stability_DELTA nor commonware_stability_EPSILON nor commonware_stability_RESERVED.
impl<P: PhasedScheme> Scheme for PhasedAsScheme<P>
Available on neither
commonware_stability_BETA nor commonware_stability_GAMMA nor commonware_stability_DELTA nor commonware_stability_EPSILON nor commonware_stability_RESERVED.Source§type Commitment = <P as PhasedScheme>::Commitment
type Commitment = <P as PhasedScheme>::Commitment
A commitment attesting to the shards of data.
Source§type Shard = <P as PhasedScheme>::StrongShard
type Shard = <P as PhasedScheme>::StrongShard
A shard of data, to be received by a participant.
Source§type CheckedShard = PhasedCheckedShard<P>
type CheckedShard = PhasedCheckedShard<P>
A shard that has been checked for inclusion in the commitment. Read more
Source§type Error = PhasedAsSchemeError<<P as PhasedScheme>::Error>
type Error = PhasedAsSchemeError<<P as PhasedScheme>::Error>
The type of errors that can occur during encoding, checking, and decoding.
Source§fn encode(
config: &Config,
data: impl Buf,
strategy: &impl Strategy,
) -> Result<(Self::Commitment, Vec<Self::Shard>), Self::Error>
fn encode( config: &Config, data: impl Buf, strategy: &impl Strategy, ) -> Result<(Self::Commitment, Vec<Self::Shard>), Self::Error>
Encode a piece of data, returning a commitment, along with shards, and proofs. Read more
impl<P: Copy> Copy for PhasedAsScheme<P>
Auto Trait Implementations§
impl<P> Freeze for PhasedAsScheme<P>
impl<P> RefUnwindSafe for PhasedAsScheme<P>where
P: RefUnwindSafe,
impl<P> Send for PhasedAsScheme<P>where
P: Send,
impl<P> Sync for PhasedAsScheme<P>where
P: Sync,
impl<P> Unpin for PhasedAsScheme<P>where
P: Unpin,
impl<P> UnsafeUnpin for PhasedAsScheme<P>
impl<P> UnwindSafe for PhasedAsScheme<P>where
P: 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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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