#[non_exhaustive]pub enum ResponseCode {
NoError = 0,
FormErr = 1,
ServFail = 2,
NXDomain = 3,
NotImp = 4,
Refused = 5,
}Expand description
Response code
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
NoError = 0
There was no error.
FormErr = 1
Format error - The name server was unable to interpret the query.
ServFail = 2
Server failure - The name server was unable to process this query due to a problem with the name server.
NXDomain = 3
Name Error - Meaningful only for responses from an authoritative name server, this code signifies that the domain name referenced in the query does not exist.
NotImp = 4
Not Implemented - The name server does not support the requested kind of query.
Refused = 5
Refused - The name server refuses to perform the specified operation for policy reasons. For example, a name server may not wish to provide the information to the particular requester, or a name server may not wish to perform a particular operation
Trait Implementations§
Source§impl Clone for ResponseCode
impl Clone for ResponseCode
Source§fn clone(&self) -> ResponseCode
fn clone(&self) -> ResponseCode
Returns a duplicate 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 ResponseCode
impl Debug for ResponseCode
Source§impl From<ResponseCode> for u16
impl From<ResponseCode> for u16
Source§fn from(flag: ResponseCode) -> Self
fn from(flag: ResponseCode) -> Self
Converts to this type from the input type.
Source§impl PartialEq for ResponseCode
impl PartialEq for ResponseCode
Source§impl TryFrom<u16> for ResponseCode
impl TryFrom<u16> for ResponseCode
impl Copy for ResponseCode
impl Eq for ResponseCode
impl StructuralPartialEq for ResponseCode
Auto Trait Implementations§
impl Freeze for ResponseCode
impl RefUnwindSafe for ResponseCode
impl Send for ResponseCode
impl Sync for ResponseCode
impl Unpin for ResponseCode
impl UnwindSafe for ResponseCode
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