pub enum DnsStatus {
NoError,
NxDomain,
ServFail,
Refused,
Other(u16),
}Expand description
A DNS response code, named as dig prints it.
Serializes as that name ("NOERROR", "NXDOMAIN", …). Codes without a
dedicated variant keep their numeric value in DnsStatus::Other and
render as their standard mnemonic (FORMERR, NOTIMP, BADVERS, …), or
RCODE<n> for an unassigned code.
Variants§
NoError
NOERROR: the query succeeded. Without records of the queried type
it is NODATA (DnsQueryResult::is_nodata) — behind a CNAME chain,
about the chain’s last target — unless it is a referral
(DnsQueryResult::referral_zone).
NxDomain
NXDOMAIN: the name does not exist — behind a CNAME chain, the
chain’s last target (a dangling CNAME).
ServFail
SERVFAIL: the server could not answer (often a DNSSEC or upstream
failure).
Refused
REFUSED: the server declined to answer.
Other(u16)
Any other response code, by its numeric value.
Implementations§
Trait Implementations§
impl Copy for DnsStatus
Source§impl<'de> Deserialize<'de> for DnsStatus
impl<'de> Deserialize<'de> for DnsStatus
Source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
impl Eq for DnsStatus
Source§impl From<ResponseCode> for DnsStatus
impl From<ResponseCode> for DnsStatus
Source§fn from(code: ResponseCode) -> Self
fn from(code: ResponseCode) -> Self
impl StructuralPartialEq for DnsStatus
Auto Trait Implementations§
impl Freeze for DnsStatus
impl RefUnwindSafe for DnsStatus
impl Send for DnsStatus
impl Sync for DnsStatus
impl Unpin for DnsStatus
impl UnsafeUnpin for DnsStatus
impl UnwindSafe for DnsStatus
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more