Trait Proof

Source
pub trait Proof<M: DbcMethod = Method>:
    Clone
    + Eq
    + Debug
    + StrictSerialize
    + StrictDeserialize
    + StrictDumb {
    type Error: Error;

    // Required methods
    fn method(&self) -> M;
    fn verify(&self, msg: &Commitment, tx: &Tx) -> Result<(), Self::Error>;
}
Expand description

Deterministic bitcoin commitment proof types.

Required Associated Types§

Source

type Error: Error

Verification error.

Required Methods§

Source

fn method(&self) -> M

Returns a single-use seal closing method used by the DBC proof.

Source

fn verify(&self, msg: &Commitment, tx: &Tx) -> Result<(), Self::Error>

Verifies DBC proof against the provided transaction.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§