pub struct IpSockDefinition<I: IpExt, D> {
pub remote_ip: SocketIpAddr<I::Addr>,
pub local_ip: IpDeviceAddr<I::Addr>,
pub device: Option<D>,
pub proto: I::Proto,
}
Expand description
The definition of an IP socket.
These values are part of the socket’s definition, and never change.
Fields§
§remote_ip: SocketIpAddr<I::Addr>
The socket’s remote address.
local_ip: IpDeviceAddr<I::Addr>
The socket’s local address.
Guaranteed to be unicast in its subnet since it’s always equal to an
address assigned to the local device. We can’t use the UnicastAddr
witness type since Ipv4Addr
doesn’t implement UnicastAddress
.
device: Option<D>
The socket’s bound output device.
proto: I::Proto
The IP protocol the socket is bound to.
Trait Implementations§
Source§impl<I: Clone + IpExt, D: Clone> Clone for IpSockDefinition<I, D>
impl<I: Clone + IpExt, D: Clone> Clone for IpSockDefinition<I, D>
Source§fn clone(&self) -> IpSockDefinition<I, D>
fn clone(&self) -> IpSockDefinition<I, D>
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreimpl<I: IpExt, D> StructuralPartialEq for IpSockDefinition<I, D>
Auto Trait Implementations§
impl<I, D> Freeze for IpSockDefinition<I, D>
impl<I, D> RefUnwindSafe for IpSockDefinition<I, D>
impl<I, D> Send for IpSockDefinition<I, D>where
D: Send,
impl<I, D> Sync for IpSockDefinition<I, D>where
D: Sync,
impl<I, D> Unpin for IpSockDefinition<I, D>
impl<I, D> UnwindSafe for IpSockDefinition<I, D>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)Source§impl<CC, BC, Meta> RecvFrameContext<Meta, BC> for CCwhere
Meta: ReceivableFrameMeta<CC, BC>,
impl<CC, BC, Meta> RecvFrameContext<Meta, BC> for CCwhere
Meta: ReceivableFrameMeta<CC, BC>,
Source§impl<CC, BC, Meta> SendFrameContext<BC, Meta> for CCwhere
Meta: SendableFrameMeta<CC, BC>,
impl<CC, BC, Meta> SendFrameContext<BC, Meta> for CCwhere
Meta: SendableFrameMeta<CC, BC>,
Source§fn send_frame<S>(
&mut self,
bindings_ctx: &mut BC,
metadata: Meta,
frame: S,
) -> Result<(), ErrorAndSerializer<SendFrameErrorReason, S>>where
S: Serializer,
<S as Serializer>::Buffer: BufferMut,
fn send_frame<S>(
&mut self,
bindings_ctx: &mut BC,
metadata: Meta,
frame: S,
) -> Result<(), ErrorAndSerializer<SendFrameErrorReason, S>>where
S: Serializer,
<S as Serializer>::Buffer: BufferMut,
Send a frame. Read more
Source§impl<Id, CC, BC> TimerHandler<BC, Id> for CCwhere
BC: TimerBindingsTypes,
Id: HandleableTimer<CC, BC>,
impl<Id, CC, BC> TimerHandler<BC, Id> for CCwhere
BC: TimerBindingsTypes,
Id: HandleableTimer<CC, BC>,
Source§fn handle_timer(
&mut self,
bindings_ctx: &mut BC,
dispatch: Id,
timer: <BC as TimerBindingsTypes>::UniqueTimerId,
)
fn handle_timer( &mut self, bindings_ctx: &mut BC, dispatch: Id, timer: <BC as TimerBindingsTypes>::UniqueTimerId, )
Handle a timer firing. Read more