pub trait DualStackDemuxIdConverter<I: DualStackIpExt>:
'static
+ Clone
+ Copy {
// Required method
fn convert<D: WeakDeviceIdentifier, BT: TcpBindingsTypes>(
&self,
id: TcpSocketId<I, D, BT>,
) -> <I::OtherVersion as DualStackBaseIpExt>::DemuxSocketId<D, BT>;
}Expand description
This trait allows us to work around the life-time issue when we need to convert an IPv6 socket ID into an IPv4 demux ID without holding on the a dual-stack CoreContext.
Required Methods§
Sourcefn convert<D: WeakDeviceIdentifier, BT: TcpBindingsTypes>(
&self,
id: TcpSocketId<I, D, BT>,
) -> <I::OtherVersion as DualStackBaseIpExt>::DemuxSocketId<D, BT>
fn convert<D: WeakDeviceIdentifier, BT: TcpBindingsTypes>( &self, id: TcpSocketId<I, D, BT>, ) -> <I::OtherVersion as DualStackBaseIpExt>::DemuxSocketId<D, BT>
Turns a TcpSocketId into the demuxer ID of the other stack.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".