Trait libp2p::core::UpgradeInfo
source · pub trait UpgradeInfo {
type Info: AsRef<str> + Clone;
type InfoIter: IntoIterator<Item = Self::Info>;
// Required method
fn protocol_info(&self) -> Self::InfoIter;
}
Expand description
Common trait for upgrades that can be applied on inbound substreams, outbound substreams, or both.
Required Associated Types§
sourcetype InfoIter: IntoIterator<Item = Self::Info>
type InfoIter: IntoIterator<Item = Self::Info>
Iterator returned by protocol_info
.
Required Methods§
sourcefn protocol_info(&self) -> Self::InfoIter
fn protocol_info(&self) -> Self::InfoIter
Returns the list of protocols that are supported. Used during the negotiation process.