[−][src]Enum networking::Message
An enumeration of all Bitcoin Wire Protocol messages, (i.e. GetHeaders, Version, Verack).
Messages are actual messages, as opposed to Command
s which are a shorthand way of referring to a type of Message.
A Message takes about 90 bytes of data on the stack, while a Command is a single byte.
Variants
Fields of Addr
addrs: Vec<EncapsulatedAddr>
Fields of BlockTxn
block_hash: [u8; 32]
txs: Vec<Transaction>
Fields of Block
block_header: BlockHeader
transactions: Vec<Transaction>
Fields of CompactBlock
Fields of FeeFilter
feerate: u64
Fields of FilterClear
Fields of GetAddr
Fields of GetBlockTxn
block_hash: [u8; 32]
indexes: Vec<CompactInt>
Fields of GetData
inventory: Vec<InventoryData>
Fields of Headers
headers: Vec<BlockHeader>
Fields of Inv
inventory: Vec<InventoryData>
Fields of MemPool
Fields of NotFound
inventory_data: Vec<InventoryData>
Fields of Ping
nonce: u64
Fields of Pong
nonce: u64
Fields of SendHeaders
Fields of Tx
transaction: Transaction
Fields of Verack
Fields of Version
Implementations
impl Message
[src]
pub fn version(
peer_ip: SocketAddr,
peer_services: u64,
warpd_ip: SocketAddr,
best_block: u32,
config: &Config
) -> Message
[src]
peer_ip: SocketAddr,
peer_services: u64,
warpd_ip: SocketAddr,
best_block: u32,
config: &Config
) -> Message
pub fn command(&self) -> Command
[src]
Trait Implementations
impl Debug for Message
[src]
impl Encoder<Message> for Codec
[src]
type Error = Error
The type of encoding errors. Read more
fn encode(
&mut self,
item: Message,
dst: &mut BytesMut
) -> Result<(), Self::Error>
[src]
&mut self,
item: Message,
dst: &mut BytesMut
) -> Result<(), Self::Error>
impl Serializable for Message
[src]
Auto Trait Implementations
impl RefUnwindSafe for Message
impl Send for Message
impl Sync for Message
impl Unpin for Message
impl UnwindSafe for Message
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,