pub struct Mapping {
pub local_ip: Ipv4Addr,
pub local_port: NonZeroU16,
pub gateway: Ipv4Addr,
pub external_port: NonZeroU16,
pub external_address: Ipv4Addr,
pub lifetime_seconds: u32,
pub nonce: [u8; 12],
}Expand description
A mapping sucessfully registered with a PCP server.
Fields§
§local_ip: Ipv4AddrLocal ip used to create this mapping.
local_port: NonZeroU16Local port used to create this mapping.
gateway: Ipv4AddrGateway address used to registed this mapping.
external_port: NonZeroU16External port of the mapping.
external_address: Ipv4AddrExternal address of the mapping.
lifetime_seconds: u32Allowed time for this mapping as informed by the server.
nonce: [u8; 12]The nonce of the mapping, used for modifications with the PCP server, for example releasing the mapping.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Mapping
impl RefUnwindSafe for Mapping
impl Send for Mapping
impl Sync for Mapping
impl Unpin for Mapping
impl UnwindSafe for Mapping
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