Enum trust_dns_proto::rr::rdata::opt::EdnsOption
source · #[non_exhaustive]pub enum EdnsOption {
Subnet(ClientSubnet),
Unknown(u16, Vec<u8>),
}
Expand description
options used to pass information about capabilities between client and server
note: Not all EdnsOptions are supported at this time.
http://www.iana.org/assignments/dns-parameters/dns-parameters.xhtml#dns-parameters-13
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.
Implementations§
Trait Implementations§
source§impl BinEncodable for EdnsOption
impl BinEncodable for EdnsOption
source§fn emit(&self, encoder: &mut BinEncoder<'_>) -> ProtoResult<()>
fn emit(&self, encoder: &mut BinEncoder<'_>) -> ProtoResult<()>
Write the type to the stream
source§impl Clone for EdnsOption
impl Clone for EdnsOption
source§fn clone(&self) -> EdnsOption
fn clone(&self) -> EdnsOption
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 EdnsOption
impl Debug for EdnsOption
source§impl<'a> From<&'a EdnsOption> for EdnsCode
impl<'a> From<&'a EdnsOption> for EdnsCode
source§fn from(value: &'a EdnsOption) -> Self
fn from(value: &'a EdnsOption) -> Self
Converts to this type from the input type.
source§impl Hash for EdnsOption
impl Hash for EdnsOption
source§impl PartialEq for EdnsOption
impl PartialEq for EdnsOption
source§fn eq(&self, other: &EdnsOption) -> bool
fn eq(&self, other: &EdnsOption) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for EdnsOption
impl PartialOrd for EdnsOption
source§fn partial_cmp(&self, other: &EdnsOption) -> Option<Ordering>
fn partial_cmp(&self, other: &EdnsOption) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl<'a> TryFrom<&'a EdnsOption> for Vec<u8>
impl<'a> TryFrom<&'a EdnsOption> for Vec<u8>
§type Error = ProtoError
type Error = ProtoError
The type returned in the event of a conversion error.
source§impl<'a> TryFrom<(EdnsCode, &'a [u8])> for EdnsOption
impl<'a> TryFrom<(EdnsCode, &'a [u8])> for EdnsOption
only the supported extensions are listed right now.
impl Eq for EdnsOption
impl StructuralPartialEq for EdnsOption
Auto Trait Implementations§
impl Freeze for EdnsOption
impl RefUnwindSafe for EdnsOption
impl Send for EdnsOption
impl Sync for EdnsOption
impl Unpin for EdnsOption
impl UnwindSafe for EdnsOption
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,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)