pub struct Interpreter;Expand description
Public script verifier. Legacy and segwit-v0 spends use bitcoinconsensus when that backend is enabled; taproot key-path spends use the local BIP341 path.
Implementations§
Source§impl Interpreter
impl Interpreter
Sourcepub const BATCH_SCHNORR_THRESHOLD: usize = 16
pub const BATCH_SCHNORR_THRESHOLD: usize = 16
Number of taproot inputs at which block validation uses the batch Schnorr path.
Sourcepub fn execute(
&self,
script_pubkey: &[u8],
script_sig: &[u8],
witness: &[Vec<u8>],
flags: VerifyFlags,
prevout: &TxOut,
tx: &Transaction,
input_idx: usize,
) -> Result<bool, ScriptError>
pub fn execute( &self, script_pubkey: &[u8], script_sig: &[u8], witness: &[Vec<u8>], flags: VerifyFlags, prevout: &TxOut, tx: &Transaction, input_idx: usize, ) -> Result<bool, ScriptError>
Executes a script spend through the enabled script backend.
Trait Implementations§
Source§impl Clone for Interpreter
impl Clone for Interpreter
Source§fn clone(&self) -> Interpreter
fn clone(&self) -> Interpreter
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Interpreter
impl Debug for Interpreter
Source§impl Default for Interpreter
impl Default for Interpreter
Source§fn default() -> Interpreter
fn default() -> Interpreter
Returns the “default value” for a type. Read more
impl Copy for Interpreter
Auto Trait Implementations§
impl Freeze for Interpreter
impl RefUnwindSafe for Interpreter
impl Send for Interpreter
impl Sync for Interpreter
impl Unpin for Interpreter
impl UnsafeUnpin for Interpreter
impl UnwindSafe for Interpreter
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> 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