Struct floresta_chain::pruned_utreexo::udata::LeafData
source · pub struct LeafData {
pub block_hash: BlockHash,
pub prevout: OutPoint,
pub header_code: u32,
pub utxo: TxOut,
}
Expand description
Leaf data is the data that is hashed when adding to utreexo state. It contains validation data and some commitments to make it harder to attack an utreexo-only node.
Fields§
§block_hash: BlockHash
A commitment to the block creating this utxo
prevout: OutPoint
The utxo’s outpoint
header_code: u32
Header code is a compact commitment to the block height and whether or not this transaction is coinbase. It’s defined as
ⓘ
header_code: u32 = if transaction.is_coinbase() {
(block_height << 1 ) | 1
} else {
block_height << 1
};
utxo: TxOut
The actual utxo
Implementations§
Trait Implementations§
source§impl PartialEq<LeafData> for LeafData
impl PartialEq<LeafData> for LeafData
impl StructuralPartialEq for LeafData
Auto Trait Implementations§
impl RefUnwindSafe for LeafData
impl Send for LeafData
impl Sync for LeafData
impl Unpin for LeafData
impl UnwindSafe for LeafData
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