pub enum QDnsName {
IpV4(Ipv4Addr),
IpV6(Ipv6Addr),
Name(Arc<String>),
}
Expand description
Variants§
Implementations§
Source§impl QDnsName
impl QDnsName
Sourcepub fn is_ipv4(&self) -> bool
pub fn is_ipv4(&self) -> bool
Answers if current type is IpV4. But does not performs check if Name is an IP in str format
Sourcepub fn is_ipv6(&self) -> bool
pub fn is_ipv6(&self) -> bool
Answers if current type is IpV6. But does not performs check if Name is an IP in str format
Sourcepub fn is_ip(&self) -> bool
pub fn is_ip(&self) -> bool
Answers if current type is IpV4 or IpV6. But does not performs check if Name is an IP in str format
Sourcepub fn get_ip_qtype(&self) -> Option<QType>
pub fn get_ip_qtype(&self) -> Option<QType>
Returns the type of the IP address version in QType format.
Trait Implementations§
impl Eq for QDnsName
impl StructuralPartialEq for QDnsName
Auto Trait Implementations§
impl Freeze for QDnsName
impl RefUnwindSafe for QDnsName
impl Send for QDnsName
impl Sync for QDnsName
impl Unpin for QDnsName
impl UnwindSafe for QDnsName
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