Enum libp2p_tcp::TcpListenerEvent
source · pub enum TcpListenerEvent<S> {
NewAddress(Multiaddr),
Upgrade {
upgrade: Ready<Result<S, Error>>,
local_addr: Multiaddr,
remote_addr: Multiaddr,
},
AddressExpired(Multiaddr),
Error(Error),
}
Expand description
Event produced by a TcpListenStream
.
Variants§
NewAddress(Multiaddr)
The listener is listening on a new additional Multiaddr
.
Upgrade
Fields
An upgrade, consisting of the upgrade future, the listener address and the remote address.
AddressExpired(Multiaddr)
A Multiaddr
is no longer used for listening.
Error(Error)
A non-fatal error has happened on the listener.
This event should be generated in order to notify the user that something wrong has happened. The listener, however, continues to run.