#[repr(u8)]pub enum ArchivedIpAddr {
V4(ArchivedIpv4Addr),
V6(ArchivedIpv6Addr),
}
Expand description
An archived IpAddr
.
Variants§
Implementations§
Source§impl ArchivedIpAddr
impl ArchivedIpAddr
Sourcepub const fn is_ipv4(&self) -> bool
pub const fn is_ipv4(&self) -> bool
Returns true
if this address is an IPv4
address, and false
otherwise.
Sourcepub const fn is_ipv6(&self) -> bool
pub const fn is_ipv6(&self) -> bool
Returns true
if this address is an IPv6
address, and false
otherwise.
Sourcepub const fn is_loopback(&self) -> bool
pub const fn is_loopback(&self) -> bool
Returns true
if this is a loopback address.
See IpAddr::is_loopback()
for more
details.
Sourcepub const fn is_multicast(&self) -> bool
pub const fn is_multicast(&self) -> bool
Returns true
if this is a multicast address.
See IpAddr::is_multicast()
for
more details.
Sourcepub const fn is_unspecified(&self) -> bool
pub const fn is_unspecified(&self) -> bool
Returns true
for the special ‘unspecified’ address.
See IpAddr::is_unspecified()
for
more details.
Trait Implementations§
Source§impl<__C: Fallible + ?Sized> CheckBytes<__C> for ArchivedIpAddrwhere
<__C as Fallible>::Error: Source,
ArchivedIpv4Addr: CheckBytes<__C>,
ArchivedIpv6Addr: CheckBytes<__C>,
impl<__C: Fallible + ?Sized> CheckBytes<__C> for ArchivedIpAddrwhere
<__C as Fallible>::Error: Source,
ArchivedIpv4Addr: CheckBytes<__C>,
ArchivedIpv6Addr: CheckBytes<__C>,
Source§impl Clone for ArchivedIpAddr
impl Clone for ArchivedIpAddr
Source§fn clone(&self) -> ArchivedIpAddr
fn clone(&self) -> ArchivedIpAddr
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 moreSource§impl Debug for ArchivedIpAddr
impl Debug for ArchivedIpAddr
Source§impl<D: Fallible + ?Sized> Deserialize<IpAddr, D> for ArchivedIpAddr
impl<D: Fallible + ?Sized> Deserialize<IpAddr, D> for ArchivedIpAddr
Source§impl Hash for ArchivedIpAddr
impl Hash for ArchivedIpAddr
Source§impl Ord for ArchivedIpAddr
impl Ord for ArchivedIpAddr
Source§fn cmp(&self, other: &ArchivedIpAddr) -> Ordering
fn cmp(&self, other: &ArchivedIpAddr) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq<ArchivedIpAddr> for IpAddr
impl PartialEq<ArchivedIpAddr> for IpAddr
Source§impl PartialEq<IpAddr> for ArchivedIpAddr
impl PartialEq<IpAddr> for ArchivedIpAddr
Source§impl PartialEq for ArchivedIpAddr
impl PartialEq for ArchivedIpAddr
Source§impl PartialOrd<ArchivedIpAddr> for IpAddr
impl PartialOrd<ArchivedIpAddr> for IpAddr
Source§impl PartialOrd<IpAddr> for ArchivedIpAddr
impl PartialOrd<IpAddr> for ArchivedIpAddr
Source§impl PartialOrd for ArchivedIpAddr
impl PartialOrd for ArchivedIpAddr
impl Copy for ArchivedIpAddr
impl Eq for ArchivedIpAddr
impl Portable for ArchivedIpAddr
impl StructuralPartialEq for ArchivedIpAddr
Auto Trait Implementations§
impl Freeze for ArchivedIpAddr
impl RefUnwindSafe for ArchivedIpAddr
impl Send for ArchivedIpAddr
impl Sync for ArchivedIpAddr
impl Unpin for ArchivedIpAddr
impl UnwindSafe for ArchivedIpAddr
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Returns the layout of the type.
Source§impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
Source§unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool
unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool
Returns whether the given value has been niched. Read more
Source§fn resolve_niched(out: Place<NichedOption<T, N1>>)
fn resolve_niched(out: Place<NichedOption<T, N1>>)
Writes data to
out
indicating that a T
is niched.