pub struct Init {
pub features: InitFeatures,
pub networks: Option<Vec<ChainHash>>,
pub remote_network_address: Option<SocketAddress>,
}
Expand description
An init
message to be sent to or received from a peer.
Fields§
§features: InitFeatures
The relevant features which the sender supports.
networks: Option<Vec<ChainHash>>
Indicates chains the sender is interested in.
If there are no common chains, the connection will be closed.
remote_network_address: Option<SocketAddress>
The receipient’s network address.
This adds the option to report a remote IP address back to a connecting peer using the init
message. A node can decide to use that information to discover a potential update to its
public IPv4 address (NAT) and use that for a NodeAnnouncement
update message containing
the new address.
Trait Implementations§
source§impl PartialEq for Init
impl PartialEq for Init
source§impl Writeable for Init
impl Writeable for Init
impl Eq for Init
impl StructuralPartialEq for Init
Auto Trait Implementations§
impl Freeze for Init
impl RefUnwindSafe for Init
impl Send for Init
impl Sync for Init
impl Unpin for Init
impl UnwindSafe for Init
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