pub struct Template(/* private fields */);
👎Deprecated
Expand description
A script template
Implementations§
Source§impl Template
impl Template
Sourcepub fn to_script(
&self,
secp: &Secp256k1,
keys: &[PublicKey],
) -> Result<Script, Error>
👎Deprecated
pub fn to_script( &self, secp: &Secp256k1, keys: &[PublicKey], ) -> Result<Script, Error>
Instantiate a template
Sourcepub fn required_keys(&self) -> usize
👎Deprecated
pub fn required_keys(&self) -> usize
Returns the number of keys this template requires to instantiate
Sourcepub fn first_push_as_number(&self) -> Option<usize>
👎Deprecated
pub fn first_push_as_number(&self) -> Option<usize>
If the first push in the template is a number, return this number. For the common case of standard multisig templates, such a number will exist and will represent the number of signatures that are required for the script to pass.
Trait Implementations§
impl Eq for Template
impl StructuralPartialEq for Template
Auto Trait Implementations§
impl Freeze for Template
impl RefUnwindSafe for Template
impl Send for Template
impl Sync for Template
impl Unpin for Template
impl UnwindSafe for Template
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