pub enum AddrType {
IPv4,
IPv6,
Either,
}
Expand description
This is the host address type to be returned by gethostbyname
.
An IPv4 address type always looks for A
records, while IPv6 address type
will look for AAAA
records
Variants§
IPv4
Result is A
record
IPv6
Result is AAAA
record
Either
Result is either a A
record, or a AAAA
record
Trait Implementations§
impl StructuralPartialEq for AddrType
Auto Trait Implementations§
impl Freeze for AddrType
impl RefUnwindSafe for AddrType
impl Send for AddrType
impl Sync for AddrType
impl Unpin for AddrType
impl UnwindSafe for AddrType
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,
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 1 byte
Size for each variant:
IPv4
: 0 bytesIPv6
: 0 bytesEither
: 0 bytes