pub enum NodeRequest {
GetBlock(Vec<BlockHash>),
GetHeaders(Vec<BlockHash>),
GetAddresses,
Shutdown,
BroadcastTransaction(Txid),
MempoolTransaction(Txid),
SendAddresses(Vec<AddrV2Message>),
GetUtreexoState((BlockHash, u32)),
GetFilter((BlockHash, u32)),
Ping,
GetBlockProof((BlockHash, Bitmap, Bitmap)),
}Expand description
Sent from node to peers, usually to request something
Variants§
GetBlock(Vec<BlockHash>)
Request the full block data for one or more blocks
GetHeaders(Vec<BlockHash>)
Asks peer for headers
GetAddresses
Ask for other peers addresses
Shutdown
Asks this peer to shutdown
BroadcastTransaction(Txid)
Sends a transaction to peers
MempoolTransaction(Txid)
Ask for an unconfirmed transaction
SendAddresses(Vec<AddrV2Message>)
Sends know addresses to our peers
GetUtreexoState((BlockHash, u32))
Requests the peer to send us the utreexo state for a given block
GetFilter((BlockHash, u32))
Requests the peer to send us the compact block filters for blocks starting at a given block hash and height.
Ping
Sends a ping to the peer to check if it’s alive
GetBlockProof((BlockHash, Bitmap, Bitmap))
Ask for the peer to send us the block proof for a given block
The first bitmap tells which proof hashes do we want, and the second which leaf data the peer should send us.
Proof hashes are the hashes needed to reconstruct the proof, while leaf data are the actual data of the leaves (i.e., the txouts).
Trait Implementations§
Source§impl Clone for NodeRequest
impl Clone for NodeRequest
Source§fn clone(&self) -> NodeRequest
fn clone(&self) -> NodeRequest
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more