pub struct CheckedProof { /* private fields */ }Expand description
A capability produced only by Headers::check. There is no unchecked
constructor or deserializer; the retained proof and header are immutable.
ⓘ
use bsv_tracker::{CheckedProof, Header, Proof};
use bsv_rs::transaction::MerklePath;
let txid = "01".repeat(32);
let proof = Proof::new(&txid, MerklePath::from_coinbase_txid(&txid, 10)).unwrap();
let header = Header { hash: "02".repeat(32), merkle_root: txid.clone() };
let _ = CheckedProof { proof, header, root: txid, depth: 1 };ⓘ
use bsv_tracker::CheckedProof;
let _ = serde_json::from_str::<CheckedProof>("{}");Implementations§
Source§impl CheckedProof
impl CheckedProof
Trait Implementations§
Source§impl Clone for CheckedProof
impl Clone for CheckedProof
Source§impl Debug for CheckedProof
impl Debug for CheckedProof
impl Eq for CheckedProof
Source§impl PartialEq for CheckedProof
impl PartialEq for CheckedProof
impl StructuralPartialEq for CheckedProof
Auto Trait Implementations§
impl Freeze for CheckedProof
impl RefUnwindSafe for CheckedProof
impl Send for CheckedProof
impl Sync for CheckedProof
impl Unpin for CheckedProof
impl UnsafeUnpin for CheckedProof
impl UnwindSafe for CheckedProof
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more