]> Untitled Git - bitcoindevkit.org/blob
86a296b13bd2ba768d804523c7868f6426ba1e02
[bitcoindevkit.org] /
1 <!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="An owned, growable script."><title>ScriptBuf in bdk_chain::bitcoin::blockdata::script - Rust</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-6b053e98.ttf.woff2,FiraSans-Regular-0fe48ade.woff2,FiraSans-Medium-e1aa3f0a.woff2,SourceCodePro-Regular-8badfe75.ttf.woff2,SourceCodePro-Semibold-aa29a496.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2" crossorigin href="../../../../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../../../../static.files/normalize-9960930a.css"><link rel="stylesheet" href="../../../../static.files/rustdoc-46132b98.css"><meta name="rustdoc-vars" data-root-path="../../../../" data-static-root-path="../../../../static.files/" data-current-crate="bdk_chain" data-themes="" data-resource-suffix="" data-rustdoc-version="1.85.0-nightly (a4cb3c831 2024-12-17)" data-channel="nightly" data-search-js="search-036cda7a.js" data-settings-js="settings-0f613d39.js" ><script src="../../../../static.files/storage-59e33391.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../../../static.files/main-5f194d8c.js"></script><noscript><link rel="stylesheet" href="../../../../static.files/noscript-893ab5e7.css"></noscript><link rel="alternate icon" type="image/png" href="../../../../static.files/favicon-32x32-6580c154.png"><link rel="icon" type="image/svg+xml" href="../../../../static.files/favicon-044be391.svg"></head><body class="rustdoc struct"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle" title="show sidebar"></button><a class="logo-container" href="../../../../bdk_chain/index.html"><img src="https://github.com/bitcoindevkit/bdk/raw/master/static/bdk.png" alt=""></a></nav><nav class="sidebar"><div class="sidebar-crate"><a class="logo-container" href="../../../../bdk_chain/index.html"><img src="https://github.com/bitcoindevkit/bdk/raw/master/static/bdk.png" alt="logo"></a><h2><a href="../../../../bdk_chain/index.html">bdk_<wbr>chain</a><span class="version">0.21.0</span></h2></div><div class="sidebar-elems"><section id="rustdoc-toc"><h2 class="location"><a href="#">Script<wbr>Buf</a></h2><h3><a href="#implementations">Methods</a></h3><ul class="block method"><li><a href="#method.as_mut_script" title="as_mut_script">as_mut_script</a></li><li><a href="#method.as_script" title="as_script">as_script</a></li><li><a href="#method.builder" title="builder">builder</a></li><li><a href="#method.from_bytes" title="from_bytes">from_bytes</a></li><li><a href="#method.from_hex" title="from_hex">from_hex</a></li><li><a href="#method.into_boxed_script" title="into_boxed_script">into_boxed_script</a></li><li><a href="#method.into_bytes" title="into_bytes">into_bytes</a></li><li><a href="#method.new" title="new">new</a></li><li><a href="#method.new_op_return" title="new_op_return">new_op_return</a></li><li><a href="#method.new_p2pk" title="new_p2pk">new_p2pk</a></li><li><a href="#method.new_p2pkh" title="new_p2pkh">new_p2pkh</a></li><li><a href="#method.new_p2sh" title="new_p2sh">new_p2sh</a></li><li><a href="#method.new_p2tr" title="new_p2tr">new_p2tr</a></li><li><a href="#method.new_p2tr_tweaked" title="new_p2tr_tweaked">new_p2tr_tweaked</a></li><li><a href="#method.new_p2wpkh" title="new_p2wpkh">new_p2wpkh</a></li><li><a href="#method.new_p2wsh" title="new_p2wsh">new_p2wsh</a></li><li><a href="#method.new_witness_program" title="new_witness_program">new_witness_program</a></li><li><a href="#method.p2wpkh_script_code" title="p2wpkh_script_code">p2wpkh_script_code</a></li><li><a href="#method.push_instruction" title="push_instruction">push_instruction</a></li><li><a href="#method.push_instruction_no_opt" title="push_instruction_no_opt">push_instruction_no_opt</a></li><li><a href="#method.push_opcode" title="push_opcode">push_opcode</a></li><li><a href="#method.push_slice" title="push_slice">push_slice</a></li><li><a href="#method.reserve" title="reserve">reserve</a></li><li><a href="#method.reserve_exact" title="reserve_exact">reserve_exact</a></li><li><a href="#method.scan_and_push_verify" title="scan_and_push_verify">scan_and_push_verify</a></li><li><a href="#method.with_capacity" title="with_capacity">with_capacity</a></li></ul><h3><a href="#deref-methods-Script">Methods from Deref&lt;<wbr>Target=<wbr>Script&gt;</a></h3><ul class="block deref-methods"><li><a href="#method.as_bytes" title="as_bytes">as_bytes</a></li><li><a href="#method.as_mut_bytes" title="as_mut_bytes">as_mut_bytes</a></li><li><a href="#method.bytes" title="bytes">bytes</a></li><li><a href="#method.count_sigops" title="count_sigops">count_sigops</a></li><li><a href="#method.count_sigops_legacy" title="count_sigops_legacy">count_sigops_legacy</a></li><li><a href="#method.dust_value" title="dust_value">dust_value</a></li><li><a href="#method.first_opcode" title="first_opcode">first_opcode</a></li><li><a href="#method.fmt_asm" title="fmt_asm">fmt_asm</a></li><li><a href="#method.instruction_indices" title="instruction_indices">instruction_indices</a></li><li><a href="#method.instruction_indices_minimal" title="instruction_indices_minimal">instruction_indices_minimal</a></li><li><a href="#method.instructions" title="instructions">instructions</a></li><li><a href="#method.instructions_minimal" title="instructions_minimal">instructions_minimal</a></li><li><a href="#method.is_empty" title="is_empty">is_empty</a></li><li><a href="#method.is_multisig" title="is_multisig">is_multisig</a></li><li><a href="#method.is_op_return" title="is_op_return">is_op_return</a></li><li><a href="#method.is_p2pk" title="is_p2pk">is_p2pk</a></li><li><a href="#method.is_p2pkh" title="is_p2pkh">is_p2pkh</a></li><li><a href="#method.is_p2sh" title="is_p2sh">is_p2sh</a></li><li><a href="#method.is_p2tr" title="is_p2tr">is_p2tr</a></li><li><a href="#method.is_p2wpkh" title="is_p2wpkh">is_p2wpkh</a></li><li><a href="#method.is_p2wsh" title="is_p2wsh">is_p2wsh</a></li><li><a href="#method.is_provably_unspendable" title="is_provably_unspendable">is_provably_unspendable</a></li><li><a href="#method.is_push_only" title="is_push_only">is_push_only</a></li><li><a href="#method.is_witness_program" title="is_witness_program">is_witness_program</a></li><li><a href="#method.len" title="len">len</a></li><li><a href="#method.minimal_non_dust" title="minimal_non_dust">minimal_non_dust</a></li><li><a href="#method.minimal_non_dust_custom" title="minimal_non_dust_custom">minimal_non_dust_custom</a></li><li><a href="#method.p2pk_public_key" title="p2pk_public_key">p2pk_public_key</a></li><li><a href="#method.p2wpkh_script_code-1" title="p2wpkh_script_code">p2wpkh_script_code</a></li><li><a href="#method.redeem_script" title="redeem_script">redeem_script</a></li><li><a href="#method.script_hash" title="script_hash">script_hash</a></li><li><a href="#method.tapscript_leaf_hash" title="tapscript_leaf_hash">tapscript_leaf_hash</a></li><li><a href="#method.to_asm_string" title="to_asm_string">to_asm_string</a></li><li><a href="#method.to_bytes" title="to_bytes">to_bytes</a></li><li><a href="#method.to_hex_string" title="to_hex_string">to_hex_string</a></li><li><a href="#method.to_p2sh" title="to_p2sh">to_p2sh</a></li><li><a href="#method.to_p2tr" title="to_p2tr">to_p2tr</a></li><li><a href="#method.to_p2wsh" title="to_p2wsh">to_p2wsh</a></li><li><a href="#method.witness_version" title="witness_version">witness_version</a></li><li><a href="#method.wscript_hash" title="wscript_hash">wscript_hash</a></li></ul><h3><a href="#trait-implementations">Trait Implementations</a></h3><ul class="block trait-implementation"><li><a href="#impl-AsMut%3CScript%3E-for-ScriptBuf" title="AsMut&#60;Script&#62;">AsMut&#60;Script&#62;</a></li><li><a href="#impl-AsMut%3C%5Bu8%5D%3E-for-ScriptBuf" title="AsMut&#60;[u8]&#62;">AsMut&#60;[u8]&#62;</a></li><li><a href="#impl-AsRef%3CScript%3E-for-ScriptBuf" title="AsRef&#60;Script&#62;">AsRef&#60;Script&#62;</a></li><li><a href="#impl-AsRef%3C%5Bu8%5D%3E-for-ScriptBuf" title="AsRef&#60;[u8]&#62;">AsRef&#60;[u8]&#62;</a></li><li><a href="#impl-Borrow%3CScript%3E-for-ScriptBuf" title="Borrow&#60;Script&#62;">Borrow&#60;Script&#62;</a></li><li><a href="#impl-BorrowMut%3CScript%3E-for-ScriptBuf" title="BorrowMut&#60;Script&#62;">BorrowMut&#60;Script&#62;</a></li><li><a href="#impl-Clone-for-ScriptBuf" title="Clone">Clone</a></li><li><a href="#impl-Debug-for-ScriptBuf" title="Debug">Debug</a></li><li><a href="#impl-Decodable-for-ScriptBuf" title="Decodable">Decodable</a></li><li><a href="#impl-Default-for-ScriptBuf" title="Default">Default</a></li><li><a href="#impl-Deref-for-ScriptBuf" title="Deref">Deref</a></li><li><a href="#impl-DerefMut-for-ScriptBuf" title="DerefMut">DerefMut</a></li><li><a href="#impl-Deserialize%3C'de%3E-for-ScriptBuf" title="Deserialize&#60;&#39;de&#62;">Deserialize&#60;&#39;de&#62;</a></li><li><a href="#impl-Display-for-ScriptBuf" title="Display">Display</a></li><li><a href="#impl-Encodable-for-ScriptBuf" title="Encodable">Encodable</a></li><li><a href="#impl-Eq-for-ScriptBuf" title="Eq">Eq</a></li><li><a href="#impl-Extend%3CInstruction%3C'a%3E%3E-for-ScriptBuf" title="Extend&#60;Instruction&#60;&#39;a&#62;&#62;">Extend&#60;Instruction&#60;&#39;a&#62;&#62;</a></li><li><a href="#impl-From%3C%26Script%3E-for-ScriptBuf" title="From&#60;&#38;&#39;a Script&#62;">From&#60;&#38;&#39;a Script&#62;</a></li><li><a href="#impl-From%3C%26ScriptBuf%3E-for-ScriptHash" title="From&#60;&#38;ScriptBuf&#62;">From&#60;&#38;ScriptBuf&#62;</a></li><li><a href="#impl-From%3C%26ScriptBuf%3E-for-WScriptHash" title="From&#60;&#38;ScriptBuf&#62;">From&#60;&#38;ScriptBuf&#62;</a></li><li><a href="#impl-From%3CAddress%3E-for-ScriptBuf" title="From&#60;Address&#62;">From&#60;Address&#62;</a></li><li><a href="#impl-From%3CCow%3C'a,+Script%3E%3E-for-ScriptBuf" title="From&#60;Cow&#60;&#39;a, Script&#62;&#62;">From&#60;Cow&#60;&#39;a, Script&#62;&#62;</a></li><li><a href="#impl-From%3CScriptBuf%3E-for-Box%3CScript%3E" title="From&#60;ScriptBuf&#62;">From&#60;ScriptBuf&#62;</a></li><li><a href="#impl-From%3CScriptBuf%3E-for-Cow%3C'_,+Script%3E" title="From&#60;ScriptBuf&#62;">From&#60;ScriptBuf&#62;</a></li><li><a href="#impl-From%3CScriptBuf%3E-for-ScriptHash" title="From&#60;ScriptBuf&#62;">From&#60;ScriptBuf&#62;</a></li><li><a href="#impl-From%3CScriptBuf%3E-for-Vec%3Cu8%3E" title="From&#60;ScriptBuf&#62;">From&#60;ScriptBuf&#62;</a></li><li><a href="#impl-From%3CScriptBuf%3E-for-WScriptHash" title="From&#60;ScriptBuf&#62;">From&#60;ScriptBuf&#62;</a></li><li><a href="#impl-From%3CVec%3Cu8%3E%3E-for-ScriptBuf" title="From&#60;Vec&#60;u8&#62;&#62;">From&#60;Vec&#60;u8&#62;&#62;</a></li><li><a href="#impl-FromIterator%3CInstruction%3C'a%3E%3E-for-ScriptBuf" title="FromIterator&#60;Instruction&#60;&#39;a&#62;&#62;">FromIterator&#60;Instruction&#60;&#39;a&#62;&#62;</a></li><li><a href="#impl-Hash-for-ScriptBuf" title="Hash">Hash</a></li><li><a href="#impl-LowerHex-for-ScriptBuf" title="LowerHex">LowerHex</a></li><li><a href="#impl-Ord-for-ScriptBuf" title="Ord">Ord</a></li><li><a href="#impl-PartialEq-for-ScriptBuf" title="PartialEq">PartialEq</a></li><li><a href="#impl-PartialEq%3CScript%3E-for-ScriptBuf" title="PartialEq&#60;Script&#62;">PartialEq&#60;Script&#62;</a></li><li><a href="#impl-PartialEq%3CScriptBuf%3E-for-Script" title="PartialEq&#60;ScriptBuf&#62;">PartialEq&#60;ScriptBuf&#62;</a></li><li><a href="#impl-PartialOrd-for-ScriptBuf" title="PartialOrd">PartialOrd</a></li><li><a href="#impl-PartialOrd%3CScript%3E-for-ScriptBuf" title="PartialOrd&#60;Script&#62;">PartialOrd&#60;Script&#62;</a></li><li><a href="#impl-PartialOrd%3CScriptBuf%3E-for-Script" title="PartialOrd&#60;ScriptBuf&#62;">PartialOrd&#60;ScriptBuf&#62;</a></li><li><a href="#impl-Serialize-for-ScriptBuf" title="Serialize">Serialize</a></li><li><a href="#impl-StructuralPartialEq-for-ScriptBuf" title="StructuralPartialEq">StructuralPartialEq</a></li><li><a href="#impl-UpperHex-for-ScriptBuf" title="UpperHex">UpperHex</a></li></ul><h3><a href="#synthetic-implementations">Auto Trait Implementations</a></h3><ul class="block synthetic-implementation"><li><a href="#impl-Freeze-for-ScriptBuf" title="Freeze">Freeze</a></li><li><a href="#impl-RefUnwindSafe-for-ScriptBuf" title="RefUnwindSafe">RefUnwindSafe</a></li><li><a href="#impl-Send-for-ScriptBuf" title="Send">Send</a></li><li><a href="#impl-Sync-for-ScriptBuf" title="Sync">Sync</a></li><li><a href="#impl-Unpin-for-ScriptBuf" title="Unpin">Unpin</a></li><li><a href="#impl-UnwindSafe-for-ScriptBuf" title="UnwindSafe">UnwindSafe</a></li></ul><h3><a href="#blanket-implementations">Blanket Implementations</a></h3><ul class="block blanket-implementation"><li><a href="#impl-Any-for-T" title="Any">Any</a></li><li><a href="#impl-Borrow%3CT%3E-for-T" title="Borrow&#60;T&#62;">Borrow&#60;T&#62;</a></li><li><a href="#impl-BorrowMut%3CT%3E-for-T" title="BorrowMut&#60;T&#62;">BorrowMut&#60;T&#62;</a></li><li><a href="#impl-CloneToUninit-for-T" title="CloneToUninit">CloneToUninit</a></li><li><a href="#impl-DeserializeOwned-for-T" title="DeserializeOwned">DeserializeOwned</a></li><li><a href="#impl-Equivalent%3CK%3E-for-Q" title="Equivalent&#60;K&#62;">Equivalent&#60;K&#62;</a></li><li><a href="#impl-From%3CT%3E-for-T" title="From&#60;T&#62;">From&#60;T&#62;</a></li><li><a href="#impl-Into%3CU%3E-for-T" title="Into&#60;U&#62;">Into&#60;U&#62;</a></li><li><a href="#impl-Receiver-for-P" title="Receiver">Receiver</a></li><li><a href="#impl-ToOwned-for-T" title="ToOwned">ToOwned</a></li><li><a href="#impl-ToString-for-T" title="ToString">ToString</a></li><li><a href="#impl-TryFrom%3CU%3E-for-T" title="TryFrom&#60;U&#62;">TryFrom&#60;U&#62;</a></li><li><a href="#impl-TryInto%3CU%3E-for-T" title="TryInto&#60;U&#62;">TryInto&#60;U&#62;</a></li><li><a href="#impl-VZip%3CV%3E-for-T" title="VZip&#60;V&#62;">VZip&#60;V&#62;</a></li></ul></section><div id="rustdoc-modnav"><h2><a href="index.html">In bdk_<wbr>chain::<wbr>bitcoin::<wbr>blockdata::<wbr>script</a></h2></div></div></nav><div class="sidebar-resizer"></div><main><div class="width-limiter"><rustdoc-search></rustdoc-search><section id="main-content" class="content"><div class="main-heading"><span class="rustdoc-breadcrumbs"><a href="../../../index.html">bdk_chain</a>::<wbr><a href="../../index.html">bitcoin</a>::<wbr><a href="../index.html">blockdata</a>::<wbr><a href="index.html">script</a></span><h1>Struct <span class="struct">ScriptBuf</span><button id="copy-path" title="Copy item path to clipboard">Copy item path</button></h1><rustdoc-toolbar></rustdoc-toolbar><span class="sub-heading"></span></div><pre class="rust item-decl"><code>pub struct ScriptBuf(<span class="comment">/* private fields */</span>);</code></pre><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>An owned, growable script.</p>
2 <p><code>ScriptBuf</code> is the most common script type that has the ownership over the contents of the
3 script. It has a close relationship with its borrowed counterpart, <a href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script"><code>Script</code></a>.</p>
4 <p>Just as other similar types, this implements [<code>Deref</code>], so <a href="https://doc.rust-lang.org/std/ops/trait.Deref.html#more-on-deref-coercion">deref coercions</a> apply. Also note
5 that all the safety/validity restrictions that apply to <a href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script"><code>Script</code></a> apply to <code>ScriptBuf</code> as well.</p>
6 </div></details><h2 id="implementations" class="section-header">Implementations<a href="#implementations" class="anchor">§</a></h2><div id="implementations-list"><details class="toggle implementors-toggle" open><summary><section id="impl-ScriptBuf" class="impl"><a href="#impl-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.new" class="method"><h4 class="code-header">pub const fn <a href="#method.new" class="fn">new</a>() -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Creates a new empty script.</p>
7 </div></details><details class="toggle method-toggle" open><summary><section id="method.with_capacity" class="method"><h4 class="code-header">pub fn <a href="#method.with_capacity" class="fn">with_capacity</a>(capacity: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Creates a new empty script with pre-allocated capacity.</p>
8 </div></details><details class="toggle method-toggle" open><summary><section id="method.reserve" class="method"><h4 class="code-header">pub fn <a href="#method.reserve" class="fn">reserve</a>(&amp;mut self, additional_len: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>)</h4></section></summary><div class="docblock"><p>Pre-allocates at least <code>additional_len</code> bytes if needed.</p>
9 <p>Reserves capacity for at least <code>additional_len</code> more bytes to be inserted in the given
10 script. The script may reserve more space to speculatively avoid frequent reallocations.
11 After calling <code>reserve</code>, capacity will be greater than or equal to
12 <code>self.len() + additional_len</code>. Does nothing if capacity is already sufficient.</p>
13 <h5 id="panics"><a class="doc-anchor" href="#panics">§</a>Panics</h5>
14 <p>Panics if the new capacity exceeds <code>isize::MAX bytes</code>.</p>
15 </div></details><details class="toggle method-toggle" open><summary><section id="method.reserve_exact" class="method"><h4 class="code-header">pub fn <a href="#method.reserve_exact" class="fn">reserve_exact</a>(&amp;mut self, additional_len: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>)</h4></section></summary><div class="docblock"><p>Pre-allocates exactly <code>additional_len</code> bytes if needed.</p>
16 <p>Unlike <code>reserve</code>, this will not deliberately over-allocate to speculatively avoid frequent
17 allocations. After calling <code>reserve_exact</code>, capacity will be greater than or equal to
18 <code>self.len() + additional</code>. Does nothing if the capacity is already sufficient.</p>
19 <p>Note that the allocator may give the collection more space than it requests. Therefore,
20 capacity can not be relied upon to be precisely minimal. Prefer <a href="../../struct.ScriptBuf.html#method.reserve" title="method bdk_chain::bitcoin::ScriptBuf::reserve"><code>reserve</code></a>
21 if future insertions are expected.</p>
22 <h5 id="panics-1"><a class="doc-anchor" href="#panics-1">§</a>Panics</h5>
23 <p>Panics if the new capacity exceeds <code>isize::MAX bytes</code>.</p>
24 </div></details><details class="toggle method-toggle" open><summary><section id="method.as_script" class="method"><h4 class="code-header">pub fn <a href="#method.as_script" class="fn">as_script</a>(&amp;self) -&gt; &amp;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a></h4></section></summary><div class="docblock"><p>Returns a reference to unsized script.</p>
25 </div></details><details class="toggle method-toggle" open><summary><section id="method.as_mut_script" class="method"><h4 class="code-header">pub fn <a href="#method.as_mut_script" class="fn">as_mut_script</a>(&amp;mut self) -&gt; &amp;mut <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a></h4></section></summary><div class="docblock"><p>Returns a mutable reference to unsized script.</p>
26 </div></details><details class="toggle method-toggle" open><summary><section id="method.builder" class="method"><h4 class="code-header">pub fn <a href="#method.builder" class="fn">builder</a>() -&gt; <a class="struct" href="struct.Builder.html" title="struct bdk_chain::bitcoin::blockdata::script::Builder">Builder</a></h4></section></summary><div class="docblock"><p>Creates a new script builder</p>
27 </div></details><details class="toggle method-toggle" open><summary><section id="method.new_p2pk" class="method"><h4 class="code-header">pub fn <a href="#method.new_p2pk" class="fn">new_p2pk</a>(pubkey: &amp;<a class="struct" href="../../struct.PublicKey.html" title="struct bdk_chain::bitcoin::PublicKey">PublicKey</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Generates P2PK-type of scriptPubkey.</p>
28 </div></details><details class="toggle method-toggle" open><summary><section id="method.new_p2pkh" class="method"><h4 class="code-header">pub fn <a href="#method.new_p2pkh" class="fn">new_p2pkh</a>(pubkey_hash: &amp;<a class="struct" href="../../struct.PubkeyHash.html" title="struct bdk_chain::bitcoin::PubkeyHash">PubkeyHash</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Generates P2PKH-type of scriptPubkey.</p>
29 </div></details><details class="toggle method-toggle" open><summary><section id="method.new_p2sh" class="method"><h4 class="code-header">pub fn <a href="#method.new_p2sh" class="fn">new_p2sh</a>(script_hash: &amp;<a class="struct" href="../../struct.ScriptHash.html" title="struct bdk_chain::bitcoin::ScriptHash">ScriptHash</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Generates P2SH-type of scriptPubkey with a given hash of the redeem script.</p>
30 </div></details><details class="toggle method-toggle" open><summary><section id="method.new_p2wpkh" class="method"><h4 class="code-header">pub fn <a href="#method.new_p2wpkh" class="fn">new_p2wpkh</a>(pubkey_hash: &amp;<a class="struct" href="../../struct.WPubkeyHash.html" title="struct bdk_chain::bitcoin::WPubkeyHash">WPubkeyHash</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Generates P2WPKH-type of scriptPubkey.</p>
31 </div></details><details class="toggle method-toggle" open><summary><section id="method.new_p2wsh" class="method"><h4 class="code-header">pub fn <a href="#method.new_p2wsh" class="fn">new_p2wsh</a>(script_hash: &amp;<a class="struct" href="../../struct.WScriptHash.html" title="struct bdk_chain::bitcoin::WScriptHash">WScriptHash</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Generates P2WSH-type of scriptPubkey with a given hash of the redeem script.</p>
32 </div></details><details class="toggle method-toggle" open><summary><section id="method.new_p2tr" class="method"><h4 class="code-header">pub fn <a href="#method.new_p2tr" class="fn">new_p2tr</a>&lt;C&gt;(
33 secp: &amp;<a class="struct" href="../../key/struct.Secp256k1.html" title="struct bdk_chain::bitcoin::key::Secp256k1">Secp256k1</a>&lt;C&gt;,
34 internal_key: <a class="struct" href="../../struct.XOnlyPublicKey.html" title="struct bdk_chain::bitcoin::XOnlyPublicKey">XOnlyPublicKey</a>,
35 merkle_root: <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="struct" href="../../struct.TapNodeHash.html" title="struct bdk_chain::bitcoin::TapNodeHash">TapNodeHash</a>&gt;,
36 ) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a><div class="where">where
37 C: <a class="trait" href="../../key/trait.Verification.html" title="trait bdk_chain::bitcoin::key::Verification">Verification</a>,</div></h4></section></summary><div class="docblock"><p>Generates P2TR for script spending path using an internal public key and some optional
38 script tree merkle root.</p>
39 </div></details><details class="toggle method-toggle" open><summary><section id="method.new_p2tr_tweaked" class="method"><h4 class="code-header">pub fn <a href="#method.new_p2tr_tweaked" class="fn">new_p2tr_tweaked</a>(output_key: <a class="struct" href="../../key/struct.TweakedPublicKey.html" title="struct bdk_chain::bitcoin::key::TweakedPublicKey">TweakedPublicKey</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Generates P2TR for key spending path for a known <a href="../../key/struct.TweakedPublicKey.html" title="struct bdk_chain::bitcoin::key::TweakedPublicKey"><code>TweakedPublicKey</code></a>.</p>
40 </div></details><details class="toggle method-toggle" open><summary><section id="method.new_witness_program" class="method"><h4 class="code-header">pub fn <a href="#method.new_witness_program" class="fn">new_witness_program</a>(witness_program: &amp;<a class="struct" href="../../struct.WitnessProgram.html" title="struct bdk_chain::bitcoin::WitnessProgram">WitnessProgram</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Generates P2WSH-type of scriptPubkey with a given <a href="../../struct.WitnessProgram.html" title="struct bdk_chain::bitcoin::WitnessProgram"><code>WitnessProgram</code></a>.</p>
41 </div></details><details class="toggle method-toggle" open><summary><section id="method.p2wpkh_script_code" class="method"><h4 class="code-header">pub fn <a href="#method.p2wpkh_script_code" class="fn">p2wpkh_script_code</a>(wpkh: <a class="struct" href="../../struct.WPubkeyHash.html" title="struct bdk_chain::bitcoin::WPubkeyHash">WPubkeyHash</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Creates the script code used for spending a P2WPKH output.</p>
42 <p>The <code>scriptCode</code> is described in <a href="https://github.com/bitcoin/bips/blob/99701f68a88ce33b2d0838eb84e115cef505b4c2/bip-0143.mediawiki">BIP143</a>.</p>
43 </div></details><details class="toggle method-toggle" open><summary><section id="method.new_op_return" class="method"><h4 class="code-header">pub fn <a href="#method.new_op_return" class="fn">new_op_return</a>&lt;T&gt;(data: T) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a><div class="where">where
44 T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsRef.html" title="trait core::convert::AsRef">AsRef</a>&lt;<a class="struct" href="struct.PushBytes.html" title="struct bdk_chain::bitcoin::blockdata::script::PushBytes">PushBytes</a>&gt;,</div></h4></section></summary><div class="docblock"><p>Generates OP_RETURN-type of scriptPubkey for the given data.</p>
45 </div></details><details class="toggle method-toggle" open><summary><section id="method.from_hex" class="method"><h4 class="code-header">pub fn <a href="#method.from_hex" class="fn">from_hex</a>(s: &amp;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.str.html">str</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>, <a class="enum" href="../../hashes/hex/enum.HexToBytesError.html" title="enum bdk_chain::bitcoin::hashes::hex::HexToBytesError">HexToBytesError</a>&gt;</h4></section></summary><div class="docblock"><p>Creates a <a href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf"><code>ScriptBuf</code></a> from a hex string.</p>
46 </div></details><details class="toggle method-toggle" open><summary><section id="method.from_bytes" class="method"><h4 class="code-header">pub fn <a href="#method.from_bytes" class="fn">from_bytes</a>(bytes: <a class="struct" href="../../base58/struct.Vec.html" title="struct bdk_chain::bitcoin::base58::Vec">Vec</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>&gt;) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Converts byte vector into script.</p>
47 <p>This method doesn’t (re)allocate.</p>
48 </div></details><details class="toggle method-toggle" open><summary><section id="method.into_bytes" class="method"><h4 class="code-header">pub fn <a href="#method.into_bytes" class="fn">into_bytes</a>(self) -&gt; <a class="struct" href="../../base58/struct.Vec.html" title="struct bdk_chain::bitcoin::base58::Vec">Vec</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>&gt; <a href="#" class="tooltip" data-notable-ty="Vec&lt;u8&gt;">ⓘ</a></h4></section></summary><div class="docblock"><p>Converts the script into a byte vector.</p>
49 <p>This method doesn’t (re)allocate.</p>
50 </div></details><details class="toggle method-toggle" open><summary><section id="method.push_opcode" class="method"><h4 class="code-header">pub fn <a href="#method.push_opcode" class="fn">push_opcode</a>(&amp;mut self, data: <a class="struct" href="../../struct.Opcode.html" title="struct bdk_chain::bitcoin::Opcode">Opcode</a>)</h4></section></summary><div class="docblock"><p>Adds a single opcode to the script.</p>
51 </div></details><details class="toggle method-toggle" open><summary><section id="method.push_slice" class="method"><h4 class="code-header">pub fn <a href="#method.push_slice" class="fn">push_slice</a>&lt;T&gt;(&amp;mut self, data: T)<div class="where">where
52 T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsRef.html" title="trait core::convert::AsRef">AsRef</a>&lt;<a class="struct" href="struct.PushBytes.html" title="struct bdk_chain::bitcoin::blockdata::script::PushBytes">PushBytes</a>&gt;,</div></h4></section></summary><div class="docblock"><p>Adds instructions to push some arbitrary data onto the stack.</p>
53 </div></details><details class="toggle method-toggle" open><summary><section id="method.push_instruction" class="method"><h4 class="code-header">pub fn <a href="#method.push_instruction" class="fn">push_instruction</a>(&amp;mut self, instruction: <a class="enum" href="enum.Instruction.html" title="enum bdk_chain::bitcoin::blockdata::script::Instruction">Instruction</a>&lt;'_&gt;)</h4></section></summary><div class="docblock"><p>Add a single instruction to the script.</p>
54 <h6 id="panics-2"><a class="doc-anchor" href="#panics-2">§</a>Panics</h6>
55 <p>The method panics if the instruction is a data push with length greater or equal to
56 0x100000000.</p>
57 </div></details><details class="toggle method-toggle" open><summary><section id="method.push_instruction_no_opt" class="method"><h4 class="code-header">pub fn <a href="#method.push_instruction_no_opt" class="fn">push_instruction_no_opt</a>(&amp;mut self, instruction: <a class="enum" href="enum.Instruction.html" title="enum bdk_chain::bitcoin::blockdata::script::Instruction">Instruction</a>&lt;'_&gt;)</h4></section></summary><div class="docblock"><p>Like push_instruction, but avoids calling <code>reserve</code> to not re-check the length.</p>
58 </div></details><details class="toggle method-toggle" open><summary><section id="method.scan_and_push_verify" class="method"><h4 class="code-header">pub fn <a href="#method.scan_and_push_verify" class="fn">scan_and_push_verify</a>(&amp;mut self)</h4></section></summary><div class="docblock"><p>Adds an <code>OP_VERIFY</code> to the script or replaces the last opcode with VERIFY form.</p>
59 <p>Some opcodes such as <code>OP_CHECKSIG</code> have a verify variant that works as if <code>VERIFY</code> was
60 in the script right after. To save space this function appends <code>VERIFY</code> only if
61 the most-recently-added opcode <em>does not</em> have an alternate <code>VERIFY</code> form. If it does
62 the last opcode is replaced. E.g., <code>OP_CHECKSIG</code> will become <code>OP_CHECKSIGVERIFY</code>.</p>
63 <p>Note that existing <code>OP_*VERIFY</code> opcodes do not lead to the instruction being ignored
64 because <code>OP_VERIFY</code> consumes an item from the stack so ignoring them would change the
65 semantics.</p>
66 <p>This function needs to iterate over the script to find the last instruction. Prefer
67 <code>Builder</code> if you’re creating the script from scratch or if you want to push <code>OP_VERIFY</code>
68 multiple times.</p>
69 </div></details><details class="toggle method-toggle" open><summary><section id="method.into_boxed_script" class="method"><h4 class="code-header">pub fn <a href="#method.into_boxed_script" class="fn">into_boxed_script</a>(self) -&gt; <a class="struct" href="https://doc.rust-lang.org/nightly/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a>&lt;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt;</h4></section></summary><div class="docblock"><p>Converts this <code>ScriptBuf</code> into a <a href="https://doc.rust-lang.org/nightly/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">boxed</a> <a href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script"><code>Script</code></a>.</p>
70 <p>This method reallocates if the capacity is greater than length of the script but should not
71 when they are equal. If you know beforehand that you need to create a script of exact size
72 use <a href="../../struct.ScriptBuf.html#method.reserve_exact" title="method bdk_chain::bitcoin::ScriptBuf::reserve_exact"><code>reserve_exact</code></a> before adding data to the script so that the
73 reallocation can be avoided.</p>
74 </div></details></div></details></div><details class="toggle big-toggle" open><summary><h2 id="deref-methods-Script" class="section-header"><span>Methods from <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Deref.html" title="trait core::ops::deref::Deref">Deref</a>&lt;Target = <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt;</span><a href="#deref-methods-Script" class="anchor">§</a></h2></summary><div id="deref-methods-Script-1" class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.as_bytes" class="method"><h4 class="code-header">pub fn <a href="#method.as_bytes" class="fn">as_bytes</a>(&amp;self) -&gt; &amp;[<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>] <a href="#" class="tooltip" data-notable-ty="&amp;[u8]">ⓘ</a></h4></section></summary><div class="docblock"><p>Returns the script data as a byte slice.</p>
75 </div></details><details class="toggle method-toggle" open><summary><section id="method.as_mut_bytes" class="method"><h4 class="code-header">pub fn <a href="#method.as_mut_bytes" class="fn">as_mut_bytes</a>(&amp;mut self) -&gt; &amp;mut [<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>] <a href="#" class="tooltip" data-notable-ty="&amp;mut [u8]">ⓘ</a></h4></section></summary><div class="docblock"><p>Returns the script data as a mutable byte slice.</p>
76 </div></details><details class="toggle method-toggle" open><summary><section id="method.script_hash" class="method"><h4 class="code-header">pub fn <a href="#method.script_hash" class="fn">script_hash</a>(&amp;self) -&gt; <a class="struct" href="../../struct.ScriptHash.html" title="struct bdk_chain::bitcoin::ScriptHash">ScriptHash</a></h4></section></summary><div class="docblock"><p>Returns 160-bit hash of the script.</p>
77 </div></details><details class="toggle method-toggle" open><summary><section id="method.wscript_hash" class="method"><h4 class="code-header">pub fn <a href="#method.wscript_hash" class="fn">wscript_hash</a>(&amp;self) -&gt; <a class="struct" href="../../struct.WScriptHash.html" title="struct bdk_chain::bitcoin::WScriptHash">WScriptHash</a></h4></section></summary><div class="docblock"><p>Returns 256-bit hash of the script for P2WSH outputs.</p>
78 </div></details><details class="toggle method-toggle" open><summary><section id="method.tapscript_leaf_hash" class="method"><h4 class="code-header">pub fn <a href="#method.tapscript_leaf_hash" class="fn">tapscript_leaf_hash</a>(&amp;self) -&gt; <a class="struct" href="../../struct.TapLeafHash.html" title="struct bdk_chain::bitcoin::TapLeafHash">TapLeafHash</a></h4></section></summary><div class="docblock"><p>Computes leaf hash of tapscript.</p>
79 </div></details><details class="toggle method-toggle" open><summary><section id="method.len" class="method"><h4 class="code-header">pub fn <a href="#method.len" class="fn">len</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a></h4></section></summary><div class="docblock"><p>Returns the length in bytes of the script.</p>
80 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_empty" class="method"><h4 class="code-header">pub fn <a href="#method.is_empty" class="fn">is_empty</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Returns whether the script is the empty script.</p>
81 </div></details><details class="toggle method-toggle" open><summary><section id="method.to_bytes" class="method"><h4 class="code-header">pub fn <a href="#method.to_bytes" class="fn">to_bytes</a>(&amp;self) -&gt; <a class="struct" href="../../base58/struct.Vec.html" title="struct bdk_chain::bitcoin::base58::Vec">Vec</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>&gt; <a href="#" class="tooltip" data-notable-ty="Vec&lt;u8&gt;">ⓘ</a></h4></section></summary><div class="docblock"><p>Returns a copy of the script data.</p>
82 </div></details><details class="toggle method-toggle" open><summary><section id="method.bytes" class="method"><h4 class="code-header">pub fn <a href="#method.bytes" class="fn">bytes</a>(&amp;self) -&gt; <a class="struct" href="struct.Bytes.html" title="struct bdk_chain::bitcoin::blockdata::script::Bytes">Bytes</a>&lt;'_&gt; <a href="#" class="tooltip" data-notable-ty="Bytes&lt;&#39;_&gt;">ⓘ</a></h4></section></summary><div class="docblock"><p>Returns an iterator over script bytes.</p>
83 </div></details><details class="toggle method-toggle" open><summary><section id="method.to_p2wsh" class="method"><h4 class="code-header">pub fn <a href="#method.to_p2wsh" class="fn">to_p2wsh</a>(&amp;self) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Computes the P2WSH output corresponding to this witnessScript (aka the “witness redeem
84 script”).</p>
85 </div></details><details class="toggle method-toggle" open><summary><section id="method.to_p2tr" class="method"><h4 class="code-header">pub fn <a href="#method.to_p2tr" class="fn">to_p2tr</a>&lt;C&gt;(
86 &amp;self,
87 secp: &amp;<a class="struct" href="../../key/struct.Secp256k1.html" title="struct bdk_chain::bitcoin::key::Secp256k1">Secp256k1</a>&lt;C&gt;,
88 internal_key: <a class="struct" href="../../struct.XOnlyPublicKey.html" title="struct bdk_chain::bitcoin::XOnlyPublicKey">XOnlyPublicKey</a>,
89 ) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a><div class="where">where
90 C: <a class="trait" href="../../key/trait.Verification.html" title="trait bdk_chain::bitcoin::key::Verification">Verification</a>,</div></h4></section></summary><div class="docblock"><p>Computes P2TR output with a given internal key and a single script spending path equal to
91 the current script, assuming that the script is a Tapscript.</p>
92 </div></details><details class="toggle method-toggle" open><summary><section id="method.witness_version" class="method"><h4 class="code-header">pub fn <a href="#method.witness_version" class="fn">witness_version</a>(&amp;self) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="enum" href="../../enum.WitnessVersion.html" title="enum bdk_chain::bitcoin::WitnessVersion">WitnessVersion</a>&gt;</h4></section></summary><div class="docblock"><p>Returns witness version of the script, if any, assuming the script is a <code>scriptPubkey</code>.</p>
93 <h5 id="returns"><a class="doc-anchor" href="#returns">§</a>Returns</h5>
94 <p>The witness version if this script is found to conform to the SegWit rules:</p>
95 <blockquote>
96 <p>A scriptPubKey (or redeemScript as defined in BIP16/P2SH) that consists of a 1-byte
97 push opcode (for 0 to 16) followed by a data push between 2 and 40 bytes gets a new
98 special meaning. The value of the first push is called the “version byte”. The following
99 byte vector pushed is called the “witness program”.</p>
100 </blockquote>
101 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_p2sh" class="method"><h4 class="code-header">pub fn <a href="#method.is_p2sh" class="fn">is_p2sh</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Checks whether a script pubkey is a P2SH output.</p>
102 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_p2pkh" class="method"><h4 class="code-header">pub fn <a href="#method.is_p2pkh" class="fn">is_p2pkh</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Checks whether a script pubkey is a P2PKH output.</p>
103 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_push_only" class="method"><h4 class="code-header">pub fn <a href="#method.is_push_only" class="fn">is_push_only</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Checks whether a script is push only.</p>
104 <p>Note: <code>OP_RESERVED</code> (<code>0x50</code>) and all the OP_PUSHNUM operations
105 are considered push operations.</p>
106 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_p2pk" class="method"><h4 class="code-header">pub fn <a href="#method.is_p2pk" class="fn">is_p2pk</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Checks whether a script pubkey is a P2PK output.</p>
107 <p>You can obtain the public key, if its valid,
108 by calling <a href="../../struct.Script.html#method.p2pk_public_key" title="method bdk_chain::bitcoin::Script::p2pk_public_key"><code>p2pk_public_key()</code></a></p>
109 </div></details><details class="toggle method-toggle" open><summary><section id="method.p2pk_public_key" class="method"><h4 class="code-header">pub fn <a href="#method.p2pk_public_key" class="fn">p2pk_public_key</a>(&amp;self) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="struct" href="../../struct.PublicKey.html" title="struct bdk_chain::bitcoin::PublicKey">PublicKey</a>&gt;</h4></section></summary><div class="docblock"><p>Returns the public key if this script is P2PK with a <strong>valid</strong> public key.</p>
110 <p>This may return <code>None</code> even when <a href="../../struct.Script.html#method.is_p2pk" title="method bdk_chain::bitcoin::Script::is_p2pk"><code>is_p2pk()</code></a> returns true.
111 This happens when the public key is invalid (e.g. the point not being on the curve).
112 In this situation the script is unspendable.</p>
113 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_multisig" class="method"><h4 class="code-header">pub fn <a href="#method.is_multisig" class="fn">is_multisig</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Checks whether a script pubkey is a bare multisig output.</p>
114 <p>In a bare multisig pubkey script the keys are not hashed, the script
115 is of the form:</p>
116 <p><code>2 &lt;pubkey1&gt; &lt;pubkey2&gt; &lt;pubkey3&gt; 3 OP_CHECKMULTISIG</code></p>
117 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_witness_program" class="method"><h4 class="code-header">pub fn <a href="#method.is_witness_program" class="fn">is_witness_program</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Checks whether a script pubkey is a Segregated Witness (segwit) program.</p>
118 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_p2wsh" class="method"><h4 class="code-header">pub fn <a href="#method.is_p2wsh" class="fn">is_p2wsh</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Checks whether a script pubkey is a P2WSH output.</p>
119 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_p2wpkh" class="method"><h4 class="code-header">pub fn <a href="#method.is_p2wpkh" class="fn">is_p2wpkh</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Checks whether a script pubkey is a P2WPKH output.</p>
120 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_p2tr" class="method"><h4 class="code-header">pub fn <a href="#method.is_p2tr" class="fn">is_p2tr</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Checks whether a script pubkey is a P2TR output.</p>
121 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_op_return" class="method"><h4 class="code-header">pub fn <a href="#method.is_op_return" class="fn">is_op_return</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Check if this is an OP_RETURN output.</p>
122 </div></details><details class="toggle method-toggle" open><summary><section id="method.is_provably_unspendable" class="method"><h4 class="code-header">pub fn <a href="#method.is_provably_unspendable" class="fn">is_provably_unspendable</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section><span class="item-info"><div class="stab deprecated"><span class="emoji">👎</span><span>Deprecated since 0.32.0: The method has potentially confusing semantics and is going to be removed, you might want <code>is_op_return</code></span></div></span></summary><div class="docblock"><p>Checks whether a script is trivially known to have no satisfying input.</p>
123 <p>This method has potentially confusing semantics and an unclear purpose, so it’s going to be
124 removed. Use <code>is_op_return</code> if you want <code>OP_RETURN</code> semantics.</p>
125 </div></details><details class="toggle method-toggle" open><summary><section id="method.to_p2sh" class="method"><h4 class="code-header">pub fn <a href="#method.to_p2sh" class="fn">to_p2sh</a>(&amp;self) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class="docblock"><p>Computes the P2SH output corresponding to this redeem script.</p>
126 </div></details><details class="toggle method-toggle" open><summary><section id="method.p2wpkh_script_code-1" class="method"><h4 class="code-header">pub fn <a href="#method.p2wpkh_script_code-1" class="fn">p2wpkh_script_code</a>(&amp;self) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>&gt;</h4></section></summary><div class="docblock"><p>Returns the script code used for spending a P2WPKH output if this script is a script pubkey
127 for a P2WPKH output. The <code>scriptCode</code> is described in <a href="https://github.com/bitcoin/bips/blob/99701f68a88ce33b2d0838eb84e115cef505b4c2/bip-0143.mediawiki">BIP143</a>.</p>
128 </div></details><details class="toggle method-toggle" open><summary><section id="method.redeem_script" class="method"><h4 class="code-header">pub fn <a href="#method.redeem_script" class="fn">redeem_script</a>(&amp;self) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;&amp;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt;</h4></section></summary><div class="docblock"><p>Get redeemScript following BIP16 rules regarding P2SH spending.</p>
129 <p>This does not guarantee that this represents a P2SH input <a href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script"><code>Script</code></a>.
130 It merely gets the last push of the script. Use
131 <a href="../../struct.Script.html#method.is_p2sh" title="method bdk_chain::bitcoin::Script::is_p2sh"><code>Script::is_p2sh</code></a> on the
132 scriptPubKey to check whether it is actually a P2SH script.</p>
133 </div></details><details class="toggle method-toggle" open><summary><section id="method.dust_value" class="method"><h4 class="code-header">pub fn <a href="#method.dust_value" class="fn">dust_value</a>(&amp;self) -&gt; <a class="struct" href="../../struct.Amount.html" title="struct bdk_chain::bitcoin::Amount">Amount</a></h4></section><span class="item-info"><div class="stab deprecated"><span class="emoji">👎</span><span>Deprecated since 0.32.0: use minimal_non_dust and friends</span></div></span></summary><div class="docblock"><p>Returns the minimum value an output with this script should have in order to be
134 broadcastable on today’s Bitcoin network.</p>
135 </div></details><details class="toggle method-toggle" open><summary><section id="method.minimal_non_dust" class="method"><h4 class="code-header">pub fn <a href="#method.minimal_non_dust" class="fn">minimal_non_dust</a>(&amp;self) -&gt; <a class="struct" href="../../struct.Amount.html" title="struct bdk_chain::bitcoin::Amount">Amount</a></h4></section></summary><div class="docblock"><p>Returns the minimum value an output with this script should have in order to be
136 broadcastable on today’s Bitcoin network.</p>
137 <p>Dust depends on the -dustrelayfee value of the Bitcoin Core node you are broadcasting to.
138 This function uses the default value of 0.00003 BTC/kB (3 sat/vByte).</p>
139 <p>To use a custom value, use <a href="../../struct.Script.html#method.minimal_non_dust_custom" title="method bdk_chain::bitcoin::Script::minimal_non_dust_custom"><code>minimal_non_dust_custom</code></a>.</p>
140 </div></details><details class="toggle method-toggle" open><summary><section id="method.minimal_non_dust_custom" class="method"><h4 class="code-header">pub fn <a href="#method.minimal_non_dust_custom" class="fn">minimal_non_dust_custom</a>(&amp;self, dust_relay_fee: <a class="struct" href="../../struct.FeeRate.html" title="struct bdk_chain::bitcoin::FeeRate">FeeRate</a>) -&gt; <a class="struct" href="../../struct.Amount.html" title="struct bdk_chain::bitcoin::Amount">Amount</a></h4></section></summary><div class="docblock"><p>Returns the minimum value an output with this script should have in order to be
141 broadcastable on today’s Bitcoin network.</p>
142 <p>Dust depends on the -dustrelayfee value of the Bitcoin Core node you are broadcasting to.
143 This function lets you set the fee rate used in dust calculation.</p>
144 <p>The current default value in Bitcoin Core (as of v26) is 3 sat/vByte.</p>
145 <p>To use the default Bitcoin Core value, use <a href="../../struct.Script.html#method.minimal_non_dust" title="method bdk_chain::bitcoin::Script::minimal_non_dust"><code>minimal_non_dust</code></a>.</p>
146 </div></details><details class="toggle method-toggle" open><summary><section id="method.count_sigops" class="method"><h4 class="code-header">pub fn <a href="#method.count_sigops" class="fn">count_sigops</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a></h4></section></summary><div class="docblock"><p>Counts the sigops for this Script using accurate counting.</p>
147 <p>In Bitcoin Core, there are two ways to count sigops, “accurate” and “legacy”.
148 This method uses “accurate” counting. This means that OP_CHECKMULTISIG and its
149 verify variant count for N sigops where N is the number of pubkeys used in the
150 multisig. However, it will count for 20 sigops if CHECKMULTISIG is not preceded by an
151 OP_PUSHNUM from 1 - 16 (this would be an invalid script)</p>
152 <p>Bitcoin Core uses accurate counting for sigops contained within redeemScripts (P2SH)
153 and witnessScripts (P2WSH) only. It uses legacy for sigops in scriptSigs and scriptPubkeys.</p>
154 <p>(Note: taproot scripts don’t count toward the sigop count of the block,
155 nor do they have CHECKMULTISIG operations. This function does not count OP_CHECKSIGADD,
156 so do not use this to try and estimate if a taproot script goes over the sigop budget.)</p>
157 </div></details><details class="toggle method-toggle" open><summary><section id="method.count_sigops_legacy" class="method"><h4 class="code-header">pub fn <a href="#method.count_sigops_legacy" class="fn">count_sigops_legacy</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a></h4></section></summary><div class="docblock"><p>Counts the sigops for this Script using legacy counting.</p>
158 <p>In Bitcoin Core, there are two ways to count sigops, “accurate” and “legacy”.
159 This method uses “legacy” counting. This means that OP_CHECKMULTISIG and its
160 verify variant count for 20 sigops.</p>
161 <p>Bitcoin Core uses legacy counting for sigops contained within scriptSigs and
162 scriptPubkeys. It uses accurate for redeemScripts (P2SH) and witnessScripts (P2WSH).</p>
163 <p>(Note: taproot scripts don’t count toward the sigop count of the block,
164 nor do they have CHECKMULTISIG operations. This function does not count OP_CHECKSIGADD,
165 so do not use this to try and estimate if a taproot script goes over the sigop budget.)</p>
166 </div></details><details class="toggle method-toggle" open><summary><section id="method.instructions" class="method"><h4 class="code-header">pub fn <a href="#method.instructions" class="fn">instructions</a>(&amp;self) -&gt; <a class="struct" href="struct.Instructions.html" title="struct bdk_chain::bitcoin::blockdata::script::Instructions">Instructions</a>&lt;'_&gt; <a href="#" class="tooltip" data-notable-ty="Instructions&lt;&#39;_&gt;">ⓘ</a></h4></section></summary><div class="docblock"><p>Iterates over the script instructions.</p>
167 <p>Each returned item is a nested enum covering opcodes, datapushes and errors.
168 At most one error will be returned and then the iterator will end. To instead iterate over
169 the script as sequence of bytes call the <a href="../../struct.Script.html#method.bytes" title="method bdk_chain::bitcoin::Script::bytes"><code>bytes</code></a> method.</p>
170 <p>To force minimal pushes, use <a href="../../struct.Script.html#method.instructions_minimal" title="method bdk_chain::bitcoin::Script::instructions_minimal"><code>instructions_minimal</code></a>.</p>
171 </div></details><details class="toggle method-toggle" open><summary><section id="method.instructions_minimal" class="method"><h4 class="code-header">pub fn <a href="#method.instructions_minimal" class="fn">instructions_minimal</a>(&amp;self) -&gt; <a class="struct" href="struct.Instructions.html" title="struct bdk_chain::bitcoin::blockdata::script::Instructions">Instructions</a>&lt;'_&gt; <a href="#" class="tooltip" data-notable-ty="Instructions&lt;&#39;_&gt;">ⓘ</a></h4></section></summary><div class="docblock"><p>Iterates over the script instructions while enforcing minimal pushes.</p>
172 <p>This is similar to <a href="../../struct.Script.html#method.instructions" title="method bdk_chain::bitcoin::Script::instructions"><code>instructions</code></a> but an error is returned if a push
173 is not minimal.</p>
174 </div></details><details class="toggle method-toggle" open><summary><section id="method.instruction_indices" class="method"><h4 class="code-header">pub fn <a href="#method.instruction_indices" class="fn">instruction_indices</a>(&amp;self) -&gt; <a class="struct" href="struct.InstructionIndices.html" title="struct bdk_chain::bitcoin::blockdata::script::InstructionIndices">InstructionIndices</a>&lt;'_&gt; <a href="#" class="tooltip" data-notable-ty="InstructionIndices&lt;&#39;_&gt;">ⓘ</a></h4></section></summary><div class="docblock"><p>Iterates over the script instructions and their indices.</p>
175 <p>Unless the script contains an error, the returned item consists of an index pointing to the
176 position in the script where the instruction begins and the decoded instruction - either an
177 opcode or data push.</p>
178 <p>To force minimal pushes, use <a href="../../struct.Script.html#method.instruction_indices_minimal" title="method bdk_chain::bitcoin::Script::instruction_indices_minimal"><code>Self::instruction_indices_minimal</code></a>.</p>
179 </div></details><details class="toggle method-toggle" open><summary><section id="method.instruction_indices_minimal" class="method"><h4 class="code-header">pub fn <a href="#method.instruction_indices_minimal" class="fn">instruction_indices_minimal</a>(&amp;self) -&gt; <a class="struct" href="struct.InstructionIndices.html" title="struct bdk_chain::bitcoin::blockdata::script::InstructionIndices">InstructionIndices</a>&lt;'_&gt; <a href="#" class="tooltip" data-notable-ty="InstructionIndices&lt;&#39;_&gt;">ⓘ</a></h4></section></summary><div class="docblock"><p>Iterates over the script instructions and their indices while enforcing minimal pushes.</p>
180 <p>This is similar to <a href="../../struct.Script.html#method.instruction_indices" title="method bdk_chain::bitcoin::Script::instruction_indices"><code>instruction_indices</code></a> but an error is
181 returned if a push is not minimal.</p>
182 </div></details><details class="toggle method-toggle" open><summary><section id="method.fmt_asm" class="method"><h4 class="code-header">pub fn <a href="#method.fmt_asm" class="fn">fmt_asm</a>(&amp;self, f: &amp;mut dyn <a class="trait" href="https://doc.rust-lang.org/nightly/core/fmt/trait.Write.html" title="trait core::fmt::Write">Write</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Error.html" title="struct core::fmt::Error">Error</a>&gt;</h4></section></summary><div class="docblock"><p>Writes the human-readable assembly representation of the script to the formatter.</p>
183 </div></details><details class="toggle method-toggle" open><summary><section id="method.to_asm_string" class="method"><h4 class="code-header">pub fn <a href="#method.to_asm_string" class="fn">to_asm_string</a>(&amp;self) -&gt; <a class="struct" href="../../base58/struct.String.html" title="struct bdk_chain::bitcoin::base58::String">String</a></h4></section></summary><div class="docblock"><p>Returns the human-readable assembly representation of the script.</p>
184 </div></details><details class="toggle method-toggle" open><summary><section id="method.to_hex_string" class="method"><h4 class="code-header">pub fn <a href="#method.to_hex_string" class="fn">to_hex_string</a>(&amp;self) -&gt; <a class="struct" href="../../base58/struct.String.html" title="struct bdk_chain::bitcoin::base58::String">String</a></h4></section></summary><div class="docblock"><p>Formats the script as lower-case hex.</p>
185 <p>This is a more convenient and performant way to write <code>format!("{:x}", script)</code>.
186 For better performance you should generally prefer displaying the script but if <code>String</code> is
187 required (this is common in tests) this method can be used.</p>
188 </div></details><details class="toggle method-toggle" open><summary><section id="method.first_opcode" class="method"><h4 class="code-header">pub fn <a href="#method.first_opcode" class="fn">first_opcode</a>(&amp;self) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="struct" href="../../struct.Opcode.html" title="struct bdk_chain::bitcoin::Opcode">Opcode</a>&gt;</h4></section></summary><div class="docblock"><p>Returns the first opcode of the script (if there is any).</p>
189 </div></details></div></details><h2 id="trait-implementations" class="section-header">Trait Implementations<a href="#trait-implementations" class="anchor">§</a></h2><div id="trait-implementations-list"><details class="toggle implementors-toggle" open><summary><section id="impl-AsMut%3C%5Bu8%5D%3E-for-ScriptBuf" class="impl"><a href="#impl-AsMut%3C%5Bu8%5D%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsMut.html" title="trait core::convert::AsMut">AsMut</a>&lt;[<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>]&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.as_mut-1" class="method trait-impl"><a href="#method.as_mut-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.AsMut.html#tymethod.as_mut" class="fn">as_mut</a>(&amp;mut self) -&gt; &amp;mut [<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>] <a href="#" class="tooltip" data-notable-ty="&amp;mut [u8]">ⓘ</a></h4></section></summary><div class='docblock'>Converts this type into a mutable reference of the (usually inferred) input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-AsMut%3CScript%3E-for-ScriptBuf" class="impl"><a href="#impl-AsMut%3CScript%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsMut.html" title="trait core::convert::AsMut">AsMut</a>&lt;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.as_mut" class="method trait-impl"><a href="#method.as_mut" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.AsMut.html#tymethod.as_mut" class="fn">as_mut</a>(&amp;mut self) -&gt; &amp;mut <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a></h4></section></summary><div class='docblock'>Converts this type into a mutable reference of the (usually inferred) input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-AsRef%3C%5Bu8%5D%3E-for-ScriptBuf" class="impl"><a href="#impl-AsRef%3C%5Bu8%5D%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsRef.html" title="trait core::convert::AsRef">AsRef</a>&lt;[<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>]&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.as_ref-1" class="method trait-impl"><a href="#method.as_ref-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.AsRef.html#tymethod.as_ref" class="fn">as_ref</a>(&amp;self) -&gt; &amp;[<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>] <a href="#" class="tooltip" data-notable-ty="&amp;[u8]">ⓘ</a></h4></section></summary><div class='docblock'>Converts this type into a shared reference of the (usually inferred) input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-AsRef%3CScript%3E-for-ScriptBuf" class="impl"><a href="#impl-AsRef%3CScript%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsRef.html" title="trait core::convert::AsRef">AsRef</a>&lt;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.as_ref" class="method trait-impl"><a href="#method.as_ref" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.AsRef.html#tymethod.as_ref" class="fn">as_ref</a>(&amp;self) -&gt; &amp;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a></h4></section></summary><div class='docblock'>Converts this type into a shared reference of the (usually inferred) input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Borrow%3CScript%3E-for-ScriptBuf" class="impl"><a href="#impl-Borrow%3CScript%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/borrow/trait.Borrow.html" title="trait core::borrow::Borrow">Borrow</a>&lt;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.borrow" class="method trait-impl"><a href="#method.borrow" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.Borrow.html#tymethod.borrow" class="fn">borrow</a>(&amp;self) -&gt; &amp;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a></h4></section></summary><div class='docblock'>Immutably borrows from an owned value. <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.Borrow.html#tymethod.borrow">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-BorrowMut%3CScript%3E-for-ScriptBuf" class="impl"><a href="#impl-BorrowMut%3CScript%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/borrow/trait.BorrowMut.html" title="trait core::borrow::BorrowMut">BorrowMut</a>&lt;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.borrow_mut" class="method trait-impl"><a href="#method.borrow_mut" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut" class="fn">borrow_mut</a>(&amp;mut self) -&gt; &amp;mut <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a></h4></section></summary><div class='docblock'>Mutably borrows from an owned value. <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Clone-for-ScriptBuf" class="impl"><a href="#impl-Clone-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.clone" class="method trait-impl"><a href="#method.clone" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#tymethod.clone" class="fn">clone</a>(&amp;self) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class='docblock'>Returns a copy of the value. <a href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#tymethod.clone">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.clone_from" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/clone.rs.html#174">Source</a></span><a href="#method.clone_from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#method.clone_from" class="fn">clone_from</a>(&amp;mut self, source: &amp;Self)</h4></section></summary><div class='docblock'>Performs copy-assignment from <code>source</code>. <a href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#method.clone_from">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Debug-for-ScriptBuf" class="impl"><a href="#impl-Debug-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.fmt" class="method trait-impl"><a href="#method.fmt" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/fmt/trait.Debug.html#tymethod.fmt" class="fn">fmt</a>(&amp;self, f: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html" title="struct core::fmt::Formatter">Formatter</a>&lt;'_&gt;) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Error.html" title="struct core::fmt::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Formats the value using the given formatter. <a href="https://doc.rust-lang.org/nightly/core/fmt/trait.Debug.html#tymethod.fmt">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Decodable-for-ScriptBuf" class="impl"><a href="#impl-Decodable-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="../../consensus/trait.Decodable.html" title="trait bdk_chain::bitcoin::consensus::Decodable">Decodable</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.consensus_decode_from_finite_reader" class="method trait-impl"><a href="#method.consensus_decode_from_finite_reader" class="anchor">§</a><h4 class="code-header">fn <a href="../../consensus/trait.Decodable.html#method.consensus_decode_from_finite_reader" class="fn">consensus_decode_from_finite_reader</a>&lt;R&gt;(r: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut R</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>, <a class="enum" href="../../consensus/encode/enum.Error.html" title="enum bdk_chain::bitcoin::consensus::encode::Error">Error</a>&gt;<div class="where">where
190 R: <a class="trait" href="../../io/trait.Read.html" title="trait bdk_chain::bitcoin::io::Read">Read</a> + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h4></section></summary><div class='docblock'>Decode <code>Self</code> from a size-limited reader. <a href="../../consensus/trait.Decodable.html#method.consensus_decode_from_finite_reader">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.consensus_decode" class="method trait-impl"><a href="#method.consensus_decode" class="anchor">§</a><h4 class="code-header">fn <a href="../../consensus/trait.Decodable.html#method.consensus_decode" class="fn">consensus_decode</a>&lt;R&gt;(reader: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut R</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;Self, <a class="enum" href="../../consensus/encode/enum.Error.html" title="enum bdk_chain::bitcoin::consensus::encode::Error">Error</a>&gt;<div class="where">where
191 R: <a class="trait" href="../../io/trait.Read.html" title="trait bdk_chain::bitcoin::io::Read">Read</a> + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h4></section></summary><div class='docblock'>Decode an object with a well-defined format. <a href="../../consensus/trait.Decodable.html#method.consensus_decode">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Default-for-ScriptBuf" class="impl"><a href="#impl-Default-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/default/trait.Default.html" title="trait core::default::Default">Default</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.default" class="method trait-impl"><a href="#method.default" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/default/trait.Default.html#tymethod.default" class="fn">default</a>() -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class='docblock'>Returns the “default value” for a type. <a href="https://doc.rust-lang.org/nightly/core/default/trait.Default.html#tymethod.default">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Deref-for-ScriptBuf" class="impl"><a href="#impl-Deref-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Deref.html" title="trait core::ops::deref::Deref">Deref</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Target" class="associatedtype trait-impl"><a href="#associatedtype.Target" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Deref.html#associatedtype.Target" class="associatedtype">Target</a> = <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a></h4></section></summary><div class='docblock'>The resulting type after dereferencing.</div></details><details class="toggle method-toggle" open><summary><section id="method.deref" class="method trait-impl"><a href="#method.deref" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Deref.html#tymethod.deref" class="fn">deref</a>(&amp;self) -&gt; &amp;&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a> as <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Deref.html" title="trait core::ops::deref::Deref">Deref</a>&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Deref.html#associatedtype.Target" title="type core::ops::deref::Deref::Target">Target</a></h4></section></summary><div class='docblock'>Dereferences the value.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-DerefMut-for-ScriptBuf" class="impl"><a href="#impl-DerefMut-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.DerefMut.html" title="trait core::ops::deref::DerefMut">DerefMut</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.deref_mut" class="method trait-impl"><a href="#method.deref_mut" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.DerefMut.html#tymethod.deref_mut" class="fn">deref_mut</a>(&amp;mut self) -&gt; &amp;mut &lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a> as <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Deref.html" title="trait core::ops::deref::Deref">Deref</a>&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Deref.html#associatedtype.Target" title="type core::ops::deref::Deref::Target">Target</a></h4></section></summary><div class='docblock'>Mutably dereferences the value.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Deserialize%3C'de%3E-for-ScriptBuf" class="impl"><a href="#impl-Deserialize%3C'de%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl&lt;'de&gt; <a class="trait" href="../../hashes/serde/trait.Deserialize.html" title="trait bdk_chain::bitcoin::hashes::serde::Deserialize">Deserialize</a>&lt;'de&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.deserialize" class="method trait-impl"><a href="#method.deserialize" class="anchor">§</a><h4 class="code-header">fn <a href="../../hashes/serde/trait.Deserialize.html#tymethod.deserialize" class="fn">deserialize</a>&lt;D&gt;(
192 deserializer: D,
193 ) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>, &lt;D as <a class="trait" href="../../hashes/serde/trait.Deserializer.html" title="trait bdk_chain::bitcoin::hashes::serde::Deserializer">Deserializer</a>&lt;'de&gt;&gt;::<a class="associatedtype" href="../../hashes/serde/trait.Deserializer.html#associatedtype.Error" title="type bdk_chain::bitcoin::hashes::serde::Deserializer::Error">Error</a>&gt;<div class="where">where
194 D: <a class="trait" href="../../hashes/serde/trait.Deserializer.html" title="trait bdk_chain::bitcoin::hashes::serde::Deserializer">Deserializer</a>&lt;'de&gt;,</div></h4></section></summary><div class='docblock'>Deserialize this value from the given Serde deserializer. <a href="../../hashes/serde/trait.Deserialize.html#tymethod.deserialize">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Display-for-ScriptBuf" class="impl"><a href="#impl-Display-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.fmt-1" class="method trait-impl"><a href="#method.fmt-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/fmt/trait.Display.html#tymethod.fmt" class="fn">fmt</a>(&amp;self, f: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html" title="struct core::fmt::Formatter">Formatter</a>&lt;'_&gt;) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Error.html" title="struct core::fmt::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Formats the value using the given formatter. <a href="https://doc.rust-lang.org/nightly/core/fmt/trait.Display.html#tymethod.fmt">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Encodable-for-ScriptBuf" class="impl"><a href="#impl-Encodable-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="../../consensus/trait.Encodable.html" title="trait bdk_chain::bitcoin::consensus::Encodable">Encodable</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.consensus_encode" class="method trait-impl"><a href="#method.consensus_encode" class="anchor">§</a><h4 class="code-header">fn <a href="../../consensus/trait.Encodable.html#tymethod.consensus_encode" class="fn">consensus_encode</a>&lt;W&gt;(&amp;self, w: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut W</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>, <a class="struct" href="../../io/struct.Error.html" title="struct bdk_chain::bitcoin::io::Error">Error</a>&gt;<div class="where">where
195 W: <a class="trait" href="../../io/trait.Write.html" title="trait bdk_chain::bitcoin::io::Write">Write</a> + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h4></section></summary><div class='docblock'>Encodes an object with a well-defined format. <a href="../../consensus/trait.Encodable.html#tymethod.consensus_encode">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Extend%3CInstruction%3C'a%3E%3E-for-ScriptBuf" class="impl"><a href="#impl-Extend%3CInstruction%3C'a%3E%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl&lt;'a&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.Extend.html" title="trait core::iter::traits::collect::Extend">Extend</a>&lt;<a class="enum" href="enum.Instruction.html" title="enum bdk_chain::bitcoin::blockdata::script::Instruction">Instruction</a>&lt;'a&gt;&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.extend" class="method trait-impl"><a href="#method.extend" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.Extend.html#tymethod.extend" class="fn">extend</a>&lt;T&gt;(&amp;mut self, iter: T)<div class="where">where
196 T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.IntoIterator.html" title="trait core::iter::traits::collect::IntoIterator">IntoIterator</a>&lt;Item = <a class="enum" href="enum.Instruction.html" title="enum bdk_chain::bitcoin::blockdata::script::Instruction">Instruction</a>&lt;'a&gt;&gt;,</div></h4></section></summary><div class='docblock'>Extends a collection with the contents of an iterator. <a href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.Extend.html#tymethod.extend">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.extend_one" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/iter/traits/collect.rs.html#453">Source</a><a href="#method.extend_one" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.Extend.html#method.extend_one" class="fn">extend_one</a>(&amp;mut self, item: A)</h4></section></summary><span class="item-info"><div class="stab unstable"><span class="emoji">🔬</span><span>This is a nightly-only experimental API. (<code>extend_one</code>)</span></div></span><div class='docblock'>Extends a collection with exactly one element.</div></details><details class="toggle method-toggle" open><summary><section id="method.extend_reserve" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/iter/traits/collect.rs.html#461">Source</a><a href="#method.extend_reserve" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.Extend.html#method.extend_reserve" class="fn">extend_reserve</a>(&amp;mut self, additional: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>)</h4></section></summary><span class="item-info"><div class="stab unstable"><span class="emoji">🔬</span><span>This is a nightly-only experimental API. (<code>extend_one</code>)</span></div></span><div class='docblock'>Reserves capacity in a collection for the given number of additional elements. <a href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.Extend.html#method.extend_reserve">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3C%26Script%3E-for-ScriptBuf" class="impl"><a href="#impl-From%3C%26Script%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl&lt;'a&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;&amp;'a <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-8" class="method trait-impl"><a href="#method.from-8" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(value: &amp;'a <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3C%26ScriptBuf%3E-for-ScriptHash" class="impl"><a href="#impl-From%3C%26ScriptBuf%3E-for-ScriptHash" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;&amp;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>&gt; for <a class="struct" href="../../struct.ScriptHash.html" title="struct bdk_chain::bitcoin::ScriptHash">ScriptHash</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-2" class="method trait-impl"><a href="#method.from-2" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(script: &amp;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="struct" href="../../struct.ScriptHash.html" title="struct bdk_chain::bitcoin::ScriptHash">ScriptHash</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3C%26ScriptBuf%3E-for-WScriptHash" class="impl"><a href="#impl-From%3C%26ScriptBuf%3E-for-WScriptHash" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;&amp;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>&gt; for <a class="struct" href="../../struct.WScriptHash.html" title="struct bdk_chain::bitcoin::WScriptHash">WScriptHash</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-4" class="method trait-impl"><a href="#method.from-4" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(script: &amp;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="struct" href="../../struct.WScriptHash.html" title="struct bdk_chain::bitcoin::WScriptHash">WScriptHash</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3CAddress%3E-for-ScriptBuf" class="impl"><a href="#impl-From%3CAddress%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;<a class="struct" href="../../struct.Address.html" title="struct bdk_chain::bitcoin::Address">Address</a>&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from" class="method trait-impl"><a href="#method.from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(a: <a class="struct" href="../../struct.Address.html" title="struct bdk_chain::bitcoin::Address">Address</a>) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3CCow%3C'a,+Script%3E%3E-for-ScriptBuf" class="impl"><a href="#impl-From%3CCow%3C'a,+Script%3E%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl&lt;'a&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;<a class="enum" href="https://doc.rust-lang.org/nightly/alloc/borrow/enum.Cow.html" title="enum alloc::borrow::Cow">Cow</a>&lt;'a, <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt;&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-7" class="method trait-impl"><a href="#method.from-7" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(value: <a class="enum" href="https://doc.rust-lang.org/nightly/alloc/borrow/enum.Cow.html" title="enum alloc::borrow::Cow">Cow</a>&lt;'a, <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt;) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3CScriptBuf%3E-for-Box%3CScript%3E" class="impl"><a href="#impl-From%3CScriptBuf%3E-for-Box%3CScript%3E" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>&gt; for <a class="struct" href="https://doc.rust-lang.org/nightly/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a>&lt;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt;</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-5" class="method trait-impl"><a href="#method.from-5" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(v: <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="struct" href="https://doc.rust-lang.org/nightly/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a>&lt;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt;</h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3CScriptBuf%3E-for-Cow%3C'_,+Script%3E" class="impl"><a href="#impl-From%3CScriptBuf%3E-for-Cow%3C'_,+Script%3E" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>&gt; for <a class="enum" href="https://doc.rust-lang.org/nightly/alloc/borrow/enum.Cow.html" title="enum alloc::borrow::Cow">Cow</a>&lt;'_, <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt;</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-6" class="method trait-impl"><a href="#method.from-6" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(value: <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/alloc/borrow/enum.Cow.html" title="enum alloc::borrow::Cow">Cow</a>&lt;'_, <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt;</h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3CScriptBuf%3E-for-ScriptHash" class="impl"><a href="#impl-From%3CScriptBuf%3E-for-ScriptHash" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>&gt; for <a class="struct" href="../../struct.ScriptHash.html" title="struct bdk_chain::bitcoin::ScriptHash">ScriptHash</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-1" class="method trait-impl"><a href="#method.from-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(script: <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="struct" href="../../struct.ScriptHash.html" title="struct bdk_chain::bitcoin::ScriptHash">ScriptHash</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3CScriptBuf%3E-for-Vec%3Cu8%3E" class="impl"><a href="#impl-From%3CScriptBuf%3E-for-Vec%3Cu8%3E" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>&gt; for <a class="struct" href="../../base58/struct.Vec.html" title="struct bdk_chain::bitcoin::base58::Vec">Vec</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>&gt;</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-10" class="method trait-impl"><a href="#method.from-10" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(v: <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="struct" href="../../base58/struct.Vec.html" title="struct bdk_chain::bitcoin::base58::Vec">Vec</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>&gt; <a href="#" class="tooltip" data-notable-ty="Vec&lt;u8&gt;">ⓘ</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3CScriptBuf%3E-for-WScriptHash" class="impl"><a href="#impl-From%3CScriptBuf%3E-for-WScriptHash" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>&gt; for <a class="struct" href="../../struct.WScriptHash.html" title="struct bdk_chain::bitcoin::WScriptHash">WScriptHash</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-3" class="method trait-impl"><a href="#method.from-3" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(script: <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="struct" href="../../struct.WScriptHash.html" title="struct bdk_chain::bitcoin::WScriptHash">WScriptHash</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-From%3CVec%3Cu8%3E%3E-for-ScriptBuf" class="impl"><a href="#impl-From%3CVec%3Cu8%3E%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;<a class="struct" href="../../base58/struct.Vec.html" title="struct bdk_chain::bitcoin::base58::Vec">Vec</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>&gt;&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-9" class="method trait-impl"><a href="#method.from-9" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(v: <a class="struct" href="../../base58/struct.Vec.html" title="struct bdk_chain::bitcoin::base58::Vec">Vec</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>&gt;) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-FromIterator%3CInstruction%3C'a%3E%3E-for-ScriptBuf" class="impl"><a href="#impl-FromIterator%3CInstruction%3C'a%3E%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl&lt;'a&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.FromIterator.html" title="trait core::iter::traits::collect::FromIterator">FromIterator</a>&lt;<a class="enum" href="enum.Instruction.html" title="enum bdk_chain::bitcoin::blockdata::script::Instruction">Instruction</a>&lt;'a&gt;&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from_iter" class="method trait-impl"><a href="#method.from_iter" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.FromIterator.html#tymethod.from_iter" class="fn">from_iter</a>&lt;T&gt;(iter: T) -&gt; <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a><div class="where">where
197 T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.IntoIterator.html" title="trait core::iter::traits::collect::IntoIterator">IntoIterator</a>&lt;Item = <a class="enum" href="enum.Instruction.html" title="enum bdk_chain::bitcoin::blockdata::script::Instruction">Instruction</a>&lt;'a&gt;&gt;,</div></h4></section></summary><div class='docblock'>Creates a value from an iterator. <a href="https://doc.rust-lang.org/nightly/core/iter/traits/collect/trait.FromIterator.html#tymethod.from_iter">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Hash-for-ScriptBuf" class="impl"><a href="#impl-Hash-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/hash/trait.Hash.html" title="trait core::hash::Hash">Hash</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.hash" class="method trait-impl"><a href="#method.hash" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/hash/trait.Hash.html#tymethod.hash" class="fn">hash</a>&lt;__H&gt;(&amp;self, state: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut __H</a>)<div class="where">where
198 __H: <a class="trait" href="https://doc.rust-lang.org/nightly/core/hash/trait.Hasher.html" title="trait core::hash::Hasher">Hasher</a>,</div></h4></section></summary><div class='docblock'>Feeds this value into the given <a href="https://doc.rust-lang.org/nightly/core/hash/trait.Hasher.html" title="trait core::hash::Hasher"><code>Hasher</code></a>. <a href="https://doc.rust-lang.org/nightly/core/hash/trait.Hash.html#tymethod.hash">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.hash_slice" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.3.0">1.3.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/hash/mod.rs.html#235-237">Source</a></span><a href="#method.hash_slice" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/hash/trait.Hash.html#method.hash_slice" class="fn">hash_slice</a>&lt;H&gt;(data: &amp;[Self], state: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut H</a>)<div class="where">where
199 H: <a class="trait" href="https://doc.rust-lang.org/nightly/core/hash/trait.Hasher.html" title="trait core::hash::Hasher">Hasher</a>,
200 Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h4></section></summary><div class='docblock'>Feeds a slice of this type into the given <a href="https://doc.rust-lang.org/nightly/core/hash/trait.Hasher.html" title="trait core::hash::Hasher"><code>Hasher</code></a>. <a href="https://doc.rust-lang.org/nightly/core/hash/trait.Hash.html#method.hash_slice">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-LowerHex-for-ScriptBuf" class="impl"><a href="#impl-LowerHex-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/fmt/trait.LowerHex.html" title="trait core::fmt::LowerHex">LowerHex</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.fmt-2" class="method trait-impl"><a href="#method.fmt-2" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/fmt/trait.LowerHex.html#tymethod.fmt" class="fn">fmt</a>(&amp;self, f: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html" title="struct core::fmt::Formatter">Formatter</a>&lt;'_&gt;) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Error.html" title="struct core::fmt::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Formats the value using the given formatter. <a href="https://doc.rust-lang.org/nightly/core/fmt/trait.LowerHex.html#tymethod.fmt">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Ord-for-ScriptBuf" class="impl"><a href="#impl-Ord-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/cmp/trait.Ord.html" title="trait core::cmp::Ord">Ord</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.cmp" class="method trait-impl"><a href="#method.cmp" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.Ord.html#tymethod.cmp" class="fn">cmp</a>(&amp;self, other: &amp;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/cmp/enum.Ordering.html" title="enum core::cmp::Ordering">Ordering</a></h4></section></summary><div class='docblock'>This method returns an <a href="https://doc.rust-lang.org/nightly/core/cmp/enum.Ordering.html" title="enum core::cmp::Ordering"><code>Ordering</code></a> between <code>self</code> and <code>other</code>. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.Ord.html#tymethod.cmp">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.max" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.21.0">1.21.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#980-982">Source</a></span><a href="#method.max" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.Ord.html#method.max" class="fn">max</a>(self, other: Self) -&gt; Self<div class="where">where
201 Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h4></section></summary><div class='docblock'>Compares and returns the maximum of two values. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.Ord.html#method.max">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.min" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.21.0">1.21.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1001-1003">Source</a></span><a href="#method.min" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.Ord.html#method.min" class="fn">min</a>(self, other: Self) -&gt; Self<div class="where">where
202 Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h4></section></summary><div class='docblock'>Compares and returns the minimum of two values. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.Ord.html#method.min">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.clamp" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.50.0">1.50.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1027-1029">Source</a></span><a href="#method.clamp" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.Ord.html#method.clamp" class="fn">clamp</a>(self, min: Self, max: Self) -&gt; Self<div class="where">where
203 Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h4></section></summary><div class='docblock'>Restrict a value to a certain interval. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.Ord.html#method.clamp">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-PartialEq%3CScript%3E-for-ScriptBuf" class="impl"><a href="#impl-PartialEq%3CScript%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialEq.html" title="trait core::cmp::PartialEq">PartialEq</a>&lt;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.eq-2" class="method trait-impl"><a href="#method.eq-2" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialEq.html#tymethod.eq" class="fn">eq</a>(&amp;self, other: &amp;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests for <code>self</code> and <code>other</code> values to be equal, and is used by <code>==</code>.</div></details><details class="toggle method-toggle" open><summary><section id="method.ne-2" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#261">Source</a></span><a href="#method.ne-2" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialEq.html#method.ne" class="fn">ne</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests for <code>!=</code>. The default implementation is almost always sufficient,
204 and should not be overridden without very good reason.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-PartialEq%3CScriptBuf%3E-for-Script" class="impl"><a href="#impl-PartialEq%3CScriptBuf%3E-for-Script" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialEq.html" title="trait core::cmp::PartialEq">PartialEq</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>&gt; for <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.eq-1" class="method trait-impl"><a href="#method.eq-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialEq.html#tymethod.eq" class="fn">eq</a>(&amp;self, other: &amp;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests for <code>self</code> and <code>other</code> values to be equal, and is used by <code>==</code>.</div></details><details class="toggle method-toggle" open><summary><section id="method.ne-1" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#261">Source</a></span><a href="#method.ne-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialEq.html#method.ne" class="fn">ne</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests for <code>!=</code>. The default implementation is almost always sufficient,
205 and should not be overridden without very good reason.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-PartialEq-for-ScriptBuf" class="impl"><a href="#impl-PartialEq-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialEq.html" title="trait core::cmp::PartialEq">PartialEq</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.eq" class="method trait-impl"><a href="#method.eq" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialEq.html#tymethod.eq" class="fn">eq</a>(&amp;self, other: &amp;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests for <code>self</code> and <code>other</code> values to be equal, and is used by <code>==</code>.</div></details><details class="toggle method-toggle" open><summary><section id="method.ne" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#261">Source</a></span><a href="#method.ne" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialEq.html#method.ne" class="fn">ne</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests for <code>!=</code>. The default implementation is almost always sufficient,
206 and should not be overridden without very good reason.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3CScript%3E-for-ScriptBuf" class="impl"><a href="#impl-PartialOrd%3CScript%3E-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html" title="trait core::cmp::PartialOrd">PartialOrd</a>&lt;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>&gt; for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.partial_cmp-1" class="method trait-impl"><a href="#method.partial_cmp-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#tymethod.partial_cmp" class="fn">partial_cmp</a>(&amp;self, other: &amp;<a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="enum" href="https://doc.rust-lang.org/nightly/core/cmp/enum.Ordering.html" title="enum core::cmp::Ordering">Ordering</a>&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#tymethod.partial_cmp">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.lt-1" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1335">Source</a></span><a href="#method.lt-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.lt" class="fn">lt</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.lt">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.le-1" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1353">Source</a></span><a href="#method.le-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.le" class="fn">le</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the
207 <code>&lt;=</code> operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.le">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.gt-1" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1371">Source</a></span><a href="#method.gt-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.gt" class="fn">gt</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code>
208 operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.gt">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.ge-1" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1389">Source</a></span><a href="#method.ge-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.ge" class="fn">ge</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by
209 the <code>&gt;=</code> operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.ge">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3CScriptBuf%3E-for-Script" class="impl"><a href="#impl-PartialOrd%3CScriptBuf%3E-for-Script" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html" title="trait core::cmp::PartialOrd">PartialOrd</a>&lt;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>&gt; for <a class="struct" href="../../struct.Script.html" title="struct bdk_chain::bitcoin::Script">Script</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.partial_cmp-2" class="method trait-impl"><a href="#method.partial_cmp-2" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#tymethod.partial_cmp" class="fn">partial_cmp</a>(&amp;self, other: &amp;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="enum" href="https://doc.rust-lang.org/nightly/core/cmp/enum.Ordering.html" title="enum core::cmp::Ordering">Ordering</a>&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#tymethod.partial_cmp">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.lt-2" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1335">Source</a></span><a href="#method.lt-2" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.lt" class="fn">lt</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.lt">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.le-2" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1353">Source</a></span><a href="#method.le-2" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.le" class="fn">le</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the
210 <code>&lt;=</code> operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.le">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.gt-2" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1371">Source</a></span><a href="#method.gt-2" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.gt" class="fn">gt</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code>
211 operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.gt">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.ge-2" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1389">Source</a></span><a href="#method.ge-2" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.ge" class="fn">ge</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by
212 the <code>&gt;=</code> operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.ge">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-PartialOrd-for-ScriptBuf" class="impl"><a href="#impl-PartialOrd-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html" title="trait core::cmp::PartialOrd">PartialOrd</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.partial_cmp" class="method trait-impl"><a href="#method.partial_cmp" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#tymethod.partial_cmp" class="fn">partial_cmp</a>(&amp;self, other: &amp;<a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="enum" href="https://doc.rust-lang.org/nightly/core/cmp/enum.Ordering.html" title="enum core::cmp::Ordering">Ordering</a>&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#tymethod.partial_cmp">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.lt" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1335">Source</a></span><a href="#method.lt" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.lt" class="fn">lt</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.lt">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.le" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1353">Source</a></span><a href="#method.le" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.le" class="fn">le</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the
213 <code>&lt;=</code> operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.le">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.gt" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1371">Source</a></span><a href="#method.gt" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.gt" class="fn">gt</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code>
214 operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.gt">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.ge" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/nightly/src/core/cmp.rs.html#1389">Source</a></span><a href="#method.ge" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.ge" class="fn">ge</a>(&amp;self, other: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;Rhs</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by
215 the <code>&gt;=</code> operator. <a href="https://doc.rust-lang.org/nightly/core/cmp/trait.PartialOrd.html#method.ge">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Serialize-for-ScriptBuf" class="impl"><a href="#impl-Serialize-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="../../hashes/serde/trait.Serialize.html" title="trait bdk_chain::bitcoin::hashes::serde::Serialize">Serialize</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.serialize" class="method trait-impl"><a href="#method.serialize" class="anchor">§</a><h4 class="code-header">fn <a href="../../hashes/serde/trait.Serialize.html#tymethod.serialize" class="fn">serialize</a>&lt;S&gt;(
216 &amp;self,
217 serializer: S,
218 ) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;&lt;S as <a class="trait" href="../../hashes/serde/trait.Serializer.html" title="trait bdk_chain::bitcoin::hashes::serde::Serializer">Serializer</a>&gt;::<a class="associatedtype" href="../../hashes/serde/trait.Serializer.html#associatedtype.Ok" title="type bdk_chain::bitcoin::hashes::serde::Serializer::Ok">Ok</a>, &lt;S as <a class="trait" href="../../hashes/serde/trait.Serializer.html" title="trait bdk_chain::bitcoin::hashes::serde::Serializer">Serializer</a>&gt;::<a class="associatedtype" href="../../hashes/serde/trait.Serializer.html#associatedtype.Error" title="type bdk_chain::bitcoin::hashes::serde::Serializer::Error">Error</a>&gt;<div class="where">where
219 S: <a class="trait" href="../../hashes/serde/trait.Serializer.html" title="trait bdk_chain::bitcoin::hashes::serde::Serializer">Serializer</a>,</div></h4></section></summary><div class="docblock"><p>User-facing serialization for <code>Script</code>.</p>
220 </div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-UpperHex-for-ScriptBuf" class="impl"><a href="#impl-UpperHex-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/fmt/trait.UpperHex.html" title="trait core::fmt::UpperHex">UpperHex</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.fmt-3" class="method trait-impl"><a href="#method.fmt-3" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/fmt/trait.UpperHex.html#tymethod.fmt" class="fn">fmt</a>(&amp;self, f: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html" title="struct core::fmt::Formatter">Formatter</a>&lt;'_&gt;) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Error.html" title="struct core::fmt::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Formats the value using the given formatter. <a href="https://doc.rust-lang.org/nightly/core/fmt/trait.UpperHex.html#tymethod.fmt">Read more</a></div></details></div></details><section id="impl-Eq-for-ScriptBuf" class="impl"><a href="#impl-Eq-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/cmp/trait.Eq.html" title="trait core::cmp::Eq">Eq</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section><section id="impl-StructuralPartialEq-for-ScriptBuf" class="impl"><a href="#impl-StructuralPartialEq-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.StructuralPartialEq.html" title="trait core::marker::StructuralPartialEq">StructuralPartialEq</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></div><h2 id="synthetic-implementations" class="section-header">Auto Trait Implementations<a href="#synthetic-implementations" class="anchor">§</a></h2><div id="synthetic-implementations-list"><section id="impl-Freeze-for-ScriptBuf" class="impl"><a href="#impl-Freeze-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Freeze.html" title="trait core::marker::Freeze">Freeze</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section><section id="impl-RefUnwindSafe-for-ScriptBuf" class="impl"><a href="#impl-RefUnwindSafe-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/panic/unwind_safe/trait.RefUnwindSafe.html" title="trait core::panic::unwind_safe::RefUnwindSafe">RefUnwindSafe</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section><section id="impl-Send-for-ScriptBuf" class="impl"><a href="#impl-Send-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section><section id="impl-Sync-for-ScriptBuf" class="impl"><a href="#impl-Sync-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section><section id="impl-Unpin-for-ScriptBuf" class="impl"><a href="#impl-Unpin-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Unpin.html" title="trait core::marker::Unpin">Unpin</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section><section id="impl-UnwindSafe-for-ScriptBuf" class="impl"><a href="#impl-UnwindSafe-for-ScriptBuf" class="anchor">§</a><h3 class="code-header">impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/panic/unwind_safe/trait.UnwindSafe.html" title="trait core::panic::unwind_safe::UnwindSafe">UnwindSafe</a> for <a class="struct" href="../../struct.ScriptBuf.html" title="struct bdk_chain::bitcoin::ScriptBuf">ScriptBuf</a></h3></section></div><h2 id="blanket-implementations" class="section-header">Blanket Implementations<a href="#blanket-implementations" class="anchor">§</a></h2><div id="blanket-implementations-list"><details class="toggle implementors-toggle"><summary><section id="impl-Any-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/any.rs.html#138">Source</a><a href="#impl-Any-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/any/trait.Any.html" title="trait core::any::Any">Any</a> for T<div class="where">where
221 T: 'static + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.type_id" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/any.rs.html#139">Source</a><a href="#method.type_id" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/any/trait.Any.html#tymethod.type_id" class="fn">type_id</a>(&amp;self) -&gt; <a class="struct" href="https://doc.rust-lang.org/nightly/core/any/struct.TypeId.html" title="struct core::any::TypeId">TypeId</a></h4></section></summary><div class='docblock'>Gets the <code>TypeId</code> of <code>self</code>. <a href="https://doc.rust-lang.org/nightly/core/any/trait.Any.html#tymethod.type_id">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-Borrow%3CT%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/borrow.rs.html#209">Source</a><a href="#impl-Borrow%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/borrow/trait.Borrow.html" title="trait core::borrow::Borrow">Borrow</a>&lt;T&gt; for T<div class="where">where
222 T: ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.borrow-1" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/borrow.rs.html#211">Source</a><a href="#method.borrow-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.Borrow.html#tymethod.borrow" class="fn">borrow</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;T</a></h4></section></summary><div class='docblock'>Immutably borrows from an owned value. <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.Borrow.html#tymethod.borrow">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-BorrowMut%3CT%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/borrow.rs.html#217">Source</a><a href="#impl-BorrowMut%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/borrow/trait.BorrowMut.html" title="trait core::borrow::BorrowMut">BorrowMut</a>&lt;T&gt; for T<div class="where">where
223 T: ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.borrow_mut-1" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/borrow.rs.html#218">Source</a><a href="#method.borrow_mut-1" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut" class="fn">borrow_mut</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut T</a></h4></section></summary><div class='docblock'>Mutably borrows from an owned value. <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-CloneToUninit-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/clone.rs.html#273">Source</a><a href="#impl-CloneToUninit-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/clone/trait.CloneToUninit.html" title="trait core::clone::CloneToUninit">CloneToUninit</a> for T<div class="where">where
224 T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.clone_to_uninit" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/clone.rs.html#275">Source</a><a href="#method.clone_to_uninit" class="anchor">§</a><h4 class="code-header">unsafe fn <a href="https://doc.rust-lang.org/nightly/core/clone/trait.CloneToUninit.html#tymethod.clone_to_uninit" class="fn">clone_to_uninit</a>(&amp;self, dst: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.pointer.html">*mut </a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>)</h4></section></summary><span class="item-info"><div class="stab unstable"><span class="emoji">🔬</span><span>This is a nightly-only experimental API. (<code>clone_to_uninit</code>)</span></div></span><div class='docblock'>Performs copy-assignment from <code>self</code> to <code>dst</code>. <a href="https://doc.rust-lang.org/nightly/core/clone/trait.CloneToUninit.html#tymethod.clone_to_uninit">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-Equivalent%3CK%3E-for-Q" class="impl"><a href="#impl-Equivalent%3CK%3E-for-Q" class="anchor">§</a><h3 class="code-header">impl&lt;Q, K&gt; Equivalent&lt;K&gt; for Q<div class="where">where
225 Q: <a class="trait" href="https://doc.rust-lang.org/nightly/core/cmp/trait.Eq.html" title="trait core::cmp::Eq">Eq</a> + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,
226 K: <a class="trait" href="https://doc.rust-lang.org/nightly/core/borrow/trait.Borrow.html" title="trait core::borrow::Borrow">Borrow</a>&lt;Q&gt; + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.equivalent" class="method trait-impl"><a href="#method.equivalent" class="anchor">§</a><h4 class="code-header">fn <a class="fn">equivalent</a>(&amp;self, key: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;K</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Checks if this value is equivalent to the given key. <a>Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-From%3CT%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#767">Source</a><a href="#impl-From%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;T&gt; for T</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from-11" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#770">Source</a><a href="#method.from-11" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(t: T) -&gt; T</h4></section></summary><div class="docblock"><p>Returns the argument unchanged.</p>
227 </div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-Into%3CU%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#750-752">Source</a><a href="#impl-Into%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a>&lt;U&gt; for T<div class="where">where
228 U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;T&gt;,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.into" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#760">Source</a><a href="#method.into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.Into.html#tymethod.into" class="fn">into</a>(self) -&gt; U</h4></section></summary><div class="docblock"><p>Calls <code>U::from(self)</code>.</p>
229 <p>That is, this conversion is whatever the implementation of
230 <code><a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;T&gt; for U</code> chooses to do.</p>
231 </div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-Receiver-for-P" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/ops/deref.rs.html#418-420">Source</a><a href="#impl-Receiver-for-P" class="anchor">§</a><h3 class="code-header">impl&lt;P, T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Receiver.html" title="trait core::ops::deref::Receiver">Receiver</a> for P<div class="where">where
232 P: <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Deref.html" title="trait core::ops::deref::Deref">Deref</a>&lt;Target = T&gt; + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,
233 T: ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Target-1" class="associatedtype trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/ops/deref.rs.html#422">Source</a><a href="#associatedtype.Target-1" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/nightly/core/ops/deref/trait.Receiver.html#associatedtype.Target" class="associatedtype">Target</a> = T</h4></section></summary><span class="item-info"><div class="stab unstable"><span class="emoji">🔬</span><span>This is a nightly-only experimental API. (<code>arbitrary_self_types</code>)</span></div></span><div class='docblock'>The target type on which the method may be called.</div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-ToOwned-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/alloc/borrow.rs.html#82-84">Source</a><a href="#impl-ToOwned-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/alloc/borrow/trait.ToOwned.html" title="trait alloc::borrow::ToOwned">ToOwned</a> for T<div class="where">where
234 T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Owned" class="associatedtype trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/alloc/borrow.rs.html#86">Source</a><a href="#associatedtype.Owned" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/nightly/alloc/borrow/trait.ToOwned.html#associatedtype.Owned" class="associatedtype">Owned</a> = T</h4></section></summary><div class='docblock'>The resulting type after obtaining ownership.</div></details><details class="toggle method-toggle" open><summary><section id="method.to_owned" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/alloc/borrow.rs.html#87">Source</a><a href="#method.to_owned" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/alloc/borrow/trait.ToOwned.html#tymethod.to_owned" class="fn">to_owned</a>(&amp;self) -&gt; T</h4></section></summary><div class='docblock'>Creates owned data from borrowed data, usually by cloning. <a href="https://doc.rust-lang.org/nightly/alloc/borrow/trait.ToOwned.html#tymethod.to_owned">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.clone_into" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/alloc/borrow.rs.html#91">Source</a><a href="#method.clone_into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/alloc/borrow/trait.ToOwned.html#method.clone_into" class="fn">clone_into</a>(&amp;self, target: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut T</a>)</h4></section></summary><div class='docblock'>Uses borrowed data to replace owned data, usually by cloning. <a href="https://doc.rust-lang.org/nightly/alloc/borrow/trait.ToOwned.html#method.clone_into">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-ToString-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/alloc/string.rs.html#2677">Source</a><a href="#impl-ToString-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/alloc/string/trait.ToString.html" title="trait alloc::string::ToString">ToString</a> for T<div class="where">where
235 T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.to_string" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/alloc/string.rs.html#2679">Source</a><a href="#method.to_string" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/alloc/string/trait.ToString.html#tymethod.to_string" class="fn">to_string</a>(&amp;self) -&gt; <a class="struct" href="../../base58/struct.String.html" title="struct bdk_chain::bitcoin::base58::String">String</a></h4></section></summary><div class='docblock'>Converts the given value to a <code>String</code>. <a href="https://doc.rust-lang.org/nightly/alloc/string/trait.ToString.html#tymethod.to_string">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-TryFrom%3CU%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#807-809">Source</a><a href="#impl-TryFrom%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;U&gt; for T<div class="where">where
236 U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a>&lt;T&gt;,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Error-1" class="associatedtype trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#811">Source</a><a href="#associatedtype.Error-1" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html#associatedtype.Error" class="associatedtype">Error</a> = <a class="enum" href="https://doc.rust-lang.org/nightly/core/convert/enum.Infallible.html" title="enum core::convert::Infallible">Infallible</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="toggle method-toggle" open><summary><section id="method.try_from" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#814">Source</a><a href="#method.try_from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html#tymethod.try_from" class="fn">try_from</a>(value: U) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;T, &lt;T as <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;U&gt;&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-TryInto%3CU%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#792-794">Source</a><a href="#impl-TryInto%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryInto.html" title="trait core::convert::TryInto">TryInto</a>&lt;U&gt; for T<div class="where">where
237 U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;T&gt;,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Error" class="associatedtype trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#796">Source</a><a href="#associatedtype.Error" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/nightly/core/convert/trait.TryInto.html#associatedtype.Error" class="associatedtype">Error</a> = &lt;U as <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;T&gt;&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="toggle method-toggle" open><summary><section id="method.try_into" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#799">Source</a><a href="#method.try_into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.TryInto.html#tymethod.try_into" class="fn">try_into</a>(self) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;U, &lt;U as <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;T&gt;&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-VZip%3CV%3E-for-T" class="impl"><a href="#impl-VZip%3CV%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;V, T&gt; VZip&lt;V&gt; for T<div class="where">where
238 V: MultiLane&lt;T&gt;,</div></h3></section></summary><div class="impl-items"><section id="method.vzip" class="method trait-impl"><a href="#method.vzip" class="anchor">§</a><h4 class="code-header">fn <a class="fn">vzip</a>(self) -&gt; V</h4></section></div></details><section id="impl-DeserializeOwned-for-T" class="impl"><a class="src rightside" href="https://docs.rs/serde/1.0.216/src/serde/de/mod.rs.html#614">Source</a><a href="#impl-DeserializeOwned-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="../../hashes/serde/de/trait.DeserializeOwned.html" title="trait bdk_chain::bitcoin::hashes::serde::de::DeserializeOwned">DeserializeOwned</a> for T<div class="where">where
239 T: for&lt;'de&gt; <a class="trait" href="../../hashes/serde/trait.Deserialize.html" title="trait bdk_chain::bitcoin::hashes::serde::Deserialize">Deserialize</a>&lt;'de&gt;,</div></h3></section></div><script type="text/json" id="notable-traits-data">{"&[u8]":"<h3>Notable traits for <code>&amp;[<a class=\"primitive\" href=\"https://doc.rust-lang.org/nightly/std/primitive.u8.html\">u8</a>]</code></h3><pre><code><div class=\"where\">impl <a class=\"trait\" href=\"https://doc.rust-lang.org/nightly/std/io/trait.Read.html\" title=\"trait std::io::Read\">Read</a> for &amp;[<a class=\"primitive\" href=\"https://doc.rust-lang.org/nightly/std/primitive.u8.html\">u8</a>]</div>","&mut [u8]":"<h3>Notable traits for <code>&amp;mut [<a class=\"primitive\" href=\"https://doc.rust-lang.org/nightly/std/primitive.u8.html\">u8</a>]</code></h3><pre><code><div class=\"where\">impl <a class=\"trait\" href=\"https://doc.rust-lang.org/nightly/std/io/trait.Write.html\" title=\"trait std::io::Write\">Write</a> for &amp;mut [<a class=\"primitive\" href=\"https://doc.rust-lang.org/nightly/std/primitive.u8.html\">u8</a>]</div>","Bytes<'_>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.Bytes.html\" title=\"struct bdk_chain::bitcoin::blockdata::script::Bytes\">Bytes</a>&lt;'_&gt;</code></h3><pre><code><div class=\"where\">impl <a class=\"trait\" href=\"https://doc.rust-lang.org/nightly/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.Bytes.html\" title=\"struct bdk_chain::bitcoin::blockdata::script::Bytes\">Bytes</a>&lt;'_&gt;</div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/nightly/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = <a class=\"primitive\" href=\"https://doc.rust-lang.org/nightly/std/primitive.u8.html\">u8</a>;</div>","InstructionIndices<'_>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.InstructionIndices.html\" title=\"struct bdk_chain::bitcoin::blockdata::script::InstructionIndices\">InstructionIndices</a>&lt;'a&gt;</code></h3><pre><code><div class=\"where\">impl&lt;'a&gt; <a class=\"trait\" href=\"https://doc.rust-lang.org/nightly/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.InstructionIndices.html\" title=\"struct bdk_chain::bitcoin::blockdata::script::InstructionIndices\">InstructionIndices</a>&lt;'a&gt;</div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/nightly/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = <a class=\"enum\" href=\"https://doc.rust-lang.org/nightly/core/result/enum.Result.html\" title=\"enum core::result::Result\">Result</a>&lt;(<a class=\"primitive\" href=\"https://doc.rust-lang.org/nightly/std/primitive.usize.html\">usize</a>, <a class=\"enum\" href=\"enum.Instruction.html\" title=\"enum bdk_chain::bitcoin::blockdata::script::Instruction\">Instruction</a>&lt;'a&gt;), <a class=\"enum\" href=\"enum.Error.html\" title=\"enum bdk_chain::bitcoin::blockdata::script::Error\">Error</a>&gt;;</div>","Instructions<'_>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.Instructions.html\" title=\"struct bdk_chain::bitcoin::blockdata::script::Instructions\">Instructions</a>&lt;'a&gt;</code></h3><pre><code><div class=\"where\">impl&lt;'a&gt; <a class=\"trait\" href=\"https://doc.rust-lang.org/nightly/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.Instructions.html\" title=\"struct bdk_chain::bitcoin::blockdata::script::Instructions\">Instructions</a>&lt;'a&gt;</div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/nightly/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = <a class=\"enum\" href=\"https://doc.rust-lang.org/nightly/core/result/enum.Result.html\" title=\"enum core::result::Result\">Result</a>&lt;<a class=\"enum\" href=\"enum.Instruction.html\" title=\"enum bdk_chain::bitcoin::blockdata::script::Instruction\">Instruction</a>&lt;'a&gt;, <a class=\"enum\" href=\"enum.Error.html\" title=\"enum bdk_chain::bitcoin::blockdata::script::Error\">Error</a>&gt;;</div>","Vec<u8>":"<h3>Notable traits for <code><a class=\"struct\" href=\"../../base58/struct.Vec.html\" title=\"struct bdk_chain::bitcoin::base58::Vec\">Vec</a>&lt;<a class=\"primitive\" href=\"https://doc.rust-lang.org/nightly/std/primitive.u8.html\">u8</a>, A&gt;</code></h3><pre><code><div class=\"where\">impl&lt;A&gt; <a class=\"trait\" href=\"https://doc.rust-lang.org/nightly/std/io/trait.Write.html\" title=\"trait std::io::Write\">Write</a> for <a class=\"struct\" href=\"../../base58/struct.Vec.html\" title=\"struct bdk_chain::bitcoin::base58::Vec\">Vec</a>&lt;<a class=\"primitive\" href=\"https://doc.rust-lang.org/nightly/std/primitive.u8.html\">u8</a>, A&gt;<div class=\"where\">where\n A: <a class=\"trait\" href=\"https://doc.rust-lang.org/nightly/core/alloc/trait.Allocator.html\" title=\"trait core::alloc::Allocator\">Allocator</a>,</div></div>"}</script></section></div></main></body></html>