Enum libp2p::identify::IdentifyEvent
source · [−]pub enum IdentifyEvent {
Received {
peer_id: PeerId,
info: IdentifyInfo,
observed_addr: Multiaddr,
},
Sent {
peer_id: PeerId,
},
Error {
peer_id: PeerId,
error: ProtocolsHandlerUpgrErr<ReadOneError>,
},
}
Expand description
Event emitted by the Identify
behaviour.
Variants
Received
Fields
peer_id: PeerId
The peer that has been identified.
info: IdentifyInfo
The information provided by the peer.
observed_addr: Multiaddr
The address observed by the peer for the local node.
Identifying information has been received from a peer.
Sent
Fields
peer_id: PeerId
The peer that the information has been sent to.
Identifying information of the local node has been sent to a peer.
Error
Fields
peer_id: PeerId
The peer with whom the error originated.
error: ProtocolsHandlerUpgrErr<ReadOneError>
The error that occurred.
Error while attempting to identify the remote.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for IdentifyEvent
impl Send for IdentifyEvent
impl Sync for IdentifyEvent
impl Unpin for IdentifyEvent
impl UnwindSafe for IdentifyEvent
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more