[−][src]Enum libp2p_core::swarm::NetworkBehaviourAction
Action to perform.
Variants
GenerateEvent(TOutEvent)
Generate an event for the outside.
DialAddress
Instructs the swarm to dial the given multiaddress without any expectation of a peer id.
Fields of DialAddress
address: Multiaddr
The address to dial.
DialPeer
Instructs the swarm to try reach the given peer.
Fields of DialPeer
peer_id: PeerId
The peer to try reach.
SendEvent
If we're connected to the given peer, sends a message to the protocol handler.
If we're not connected to this peer, does nothing. If necessary, the implementation of
NetworkBehaviour
is supposed to track which peers we are connected to.
Fields of SendEvent
ReportObservedAddr
Reports that a remote observes us as this address.
The swarm will pass this address through the transport's NAT traversal.
Fields of ReportObservedAddr
address: Multiaddr
The address we're being observed as.
Trait Implementations
impl<TInEvent: Clone, TOutEvent: Clone> Clone for NetworkBehaviourAction<TInEvent, TOutEvent>
[src]
fn clone(&self) -> NetworkBehaviourAction<TInEvent, TOutEvent>
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<TInEvent: Debug, TOutEvent: Debug> Debug for NetworkBehaviourAction<TInEvent, TOutEvent>
[src]
Auto Trait Implementations
impl<TInEvent, TOutEvent> Send for NetworkBehaviourAction<TInEvent, TOutEvent> where
TInEvent: Send,
TOutEvent: Send,
TInEvent: Send,
TOutEvent: Send,
impl<TInEvent, TOutEvent> Sync for NetworkBehaviourAction<TInEvent, TOutEvent> where
TInEvent: Sync,
TOutEvent: Sync,
TInEvent: Sync,
TOutEvent: Sync,
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
try_from
)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> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Same for T
type Output = T
Should always be Self