pub struct NoClientWitness<Seal>(/* private fields */)
where
Seal: SingleUseSeal;
Expand description
Some single-use seal protocols may not distinguish client-side seal closing
witness and have just the published one. To use SealWitness
type in such
protocols, the SingleUseSeal
must set its SingleUseSeal::CliWitness
to NoClientWitness
type.
Implementations§
Source§impl<Seal> NoClientWitness<Seal>where
Seal: SingleUseSeal,
impl<Seal> NoClientWitness<Seal>where
Seal: SingleUseSeal,
Sourcepub fn new() -> NoClientWitness<Seal>
pub fn new() -> NoClientWitness<Seal>
Constructs the object.
Trait Implementations§
Source§impl<Seal> ClientSideWitness for NoClientWitness<Seal>where
Seal: SingleUseSeal,
impl<Seal> ClientSideWitness for NoClientWitness<Seal>where
Seal: SingleUseSeal,
Source§type Seal = Seal
type Seal = Seal
Client-side witness is specific to just one type of single-use seals,
provided as an associated type.
Source§type Proof = <Seal as SingleUseSeal>::Message
type Proof = <Seal as SingleUseSeal>::Message
Proof which is passed from the client-side witness to the public-side
witness during single-use seal validation.
Source§type Error = Infallible
type Error = Infallible
Error type returned by the
Self::convolve_commit
operation.Source§fn convolve_commit(
&self,
msg: <Seal as SingleUseSeal>::Message,
) -> Result<<NoClientWitness<Seal> as ClientSideWitness>::Proof, <NoClientWitness<Seal> as ClientSideWitness>::Error>
fn convolve_commit( &self, msg: <Seal as SingleUseSeal>::Message, ) -> Result<<NoClientWitness<Seal> as ClientSideWitness>::Proof, <NoClientWitness<Seal> as ClientSideWitness>::Error>
Procedure that convolves the message with the client-side data kept in
the client-side part of the seal closing witness. This produces
Self::Proof
, which is lately verified by
SealWitness::verify_seal_closing
and
SealWitness::verify_seals_closing
against the published part of the
witness.Source§fn merge(&mut self, _: NoClientWitness<Seal>) -> Result<(), impl Error>where
NoClientWitness<Seal>: Sized,
fn merge(&mut self, _: NoClientWitness<Seal>) -> Result<(), impl Error>where
NoClientWitness<Seal>: Sized,
Merge two compatible client-side witnesses together, or error in case of
their incompatibility. Read more
Source§impl<Seal> Clone for NoClientWitness<Seal>where
Seal: Clone + SingleUseSeal,
impl<Seal> Clone for NoClientWitness<Seal>where
Seal: Clone + SingleUseSeal,
Source§fn clone(&self) -> NoClientWitness<Seal>
fn clone(&self) -> NoClientWitness<Seal>
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<Seal> Debug for NoClientWitness<Seal>where
Seal: Debug + SingleUseSeal,
impl<Seal> Debug for NoClientWitness<Seal>where
Seal: Debug + SingleUseSeal,
Source§impl<Seal> Default for NoClientWitness<Seal>where
Seal: SingleUseSeal,
impl<Seal> Default for NoClientWitness<Seal>where
Seal: SingleUseSeal,
Source§fn default() -> NoClientWitness<Seal>
fn default() -> NoClientWitness<Seal>
Returns the “default value” for a type. Read more
Source§impl<Seal> PartialEq for NoClientWitness<Seal>where
Seal: SingleUseSeal,
impl<Seal> PartialEq for NoClientWitness<Seal>where
Seal: SingleUseSeal,
Source§impl<Seal> StrictDecode for NoClientWitness<Seal>where
Seal: SingleUseSeal,
impl<Seal> StrictDecode for NoClientWitness<Seal>where
Seal: SingleUseSeal,
fn strict_decode( _reader: &mut impl TypedRead, ) -> Result<NoClientWitness<Seal>, DecodeError>
fn strict_read(reader: impl ReadRaw) -> Result<Self, DecodeError>
Source§impl<Seal> StrictEncode for NoClientWitness<Seal>where
Seal: SingleUseSeal,
impl<Seal> StrictEncode for NoClientWitness<Seal>where
Seal: SingleUseSeal,
fn strict_encode<W>(&self, writer: W) -> Result<W, Error>where
W: TypedWrite,
fn strict_write(&self, writer: impl WriteRaw) -> Result<(), Error>
Source§impl<Seal> StrictTuple for NoClientWitness<Seal>where
Seal: SingleUseSeal,
impl<Seal> StrictTuple for NoClientWitness<Seal>where
Seal: SingleUseSeal,
const FIELD_COUNT: u8 = 0u8
fn strict_check_fields()
fn strict_type_info() -> TypeInfo<Self>
Source§impl<Seal> StrictType for NoClientWitness<Seal>where
Seal: SingleUseSeal,
impl<Seal> StrictType for NoClientWitness<Seal>where
Seal: SingleUseSeal,
const STRICT_LIB_NAME: &'static str = LIB_NAME_SEALS
fn strict_name() -> Option<TypeName>
impl<Seal> Copy for NoClientWitness<Seal>where
Seal: Copy + SingleUseSeal,
impl<Seal> Eq for NoClientWitness<Seal>where
Seal: SingleUseSeal,
impl<Seal> StrictProduct for NoClientWitness<Seal>where
Seal: SingleUseSeal,
Auto Trait Implementations§
impl<Seal> Freeze for NoClientWitness<Seal>
impl<Seal> RefUnwindSafe for NoClientWitness<Seal>where
Seal: RefUnwindSafe,
impl<Seal> Send for NoClientWitness<Seal>where
Seal: Send,
impl<Seal> Sync for NoClientWitness<Seal>where
Seal: Sync,
impl<Seal> Unpin for NoClientWitness<Seal>where
Seal: Unpin,
impl<Seal> UnwindSafe for NoClientWitness<Seal>where
Seal: 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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.