pub struct SvcParamKey(/* private fields */);
Implementations§
source§impl SvcParamKey
impl SvcParamKey
pub const MANDATORY: SvcParamKey = _
pub const ALPN: SvcParamKey = _
pub const NO_DEFAULT_ALPN: SvcParamKey = _
pub const PORT: SvcParamKey = _
pub const IPV4HINT: SvcParamKey = _
pub const ECH: SvcParamKey = _
pub const IPV6HINT: SvcParamKey = _
pub const DOHPATH: SvcParamKey = _
source§impl SvcParamKey
impl SvcParamKey
pub const COMPOSE_LEN: u16 = 2u16
sourcepub fn from_mnemonic(m: &[u8]) -> Option<Self>
pub fn from_mnemonic(m: &[u8]) -> Option<Self>
Returns a value from a well-defined mnemonic.
sourcepub const fn to_mnemonic(self) -> Option<&'static [u8]>
pub const fn to_mnemonic(self) -> Option<&'static [u8]>
Returns the mnemonic for this value if there is one.
This will also return a mnemonic if a well-defined variant
is hidden in a Int
variant.
pub fn parse<'a, Octs: AsRef<[u8]> + ?Sized>( parser: &mut Parser<'a, Octs>, ) -> Result<Self, ParseError>
pub fn compose<Target: OctetsBuilder + ?Sized>( &self, target: &mut Target, ) -> Result<(), Target::AppendError>
source§impl SvcParamKey
impl SvcParamKey
pub fn from_bytes(bytes: &[u8]) -> Option<Self>
source§impl SvcParamKey
impl SvcParamKey
pub const PRIVATE_RANGE_BEGIN: u16 = 65_280u16
pub const PRIVATE_RANGE_END: u16 = 65_534u16
pub const INVALID: Self = _
Trait Implementations§
source§impl Clone for SvcParamKey
impl Clone for SvcParamKey
source§fn clone(&self) -> SvcParamKey
fn clone(&self) -> SvcParamKey
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 SvcParamKey
impl Debug for SvcParamKey
source§impl Display for SvcParamKey
impl Display for SvcParamKey
source§impl<'a> From<&'a SvcParamKey> for u16
impl<'a> From<&'a SvcParamKey> for u16
source§fn from(value: &'a SvcParamKey) -> Self
fn from(value: &'a SvcParamKey) -> Self
Converts to this type from the input type.
source§impl From<SvcParamKey> for u16
impl From<SvcParamKey> for u16
source§fn from(value: SvcParamKey) -> Self
fn from(value: SvcParamKey) -> Self
Converts to this type from the input type.
source§impl From<u16> for SvcParamKey
impl From<u16> for SvcParamKey
source§impl FromStr for SvcParamKey
impl FromStr for SvcParamKey
source§impl Hash for SvcParamKey
impl Hash for SvcParamKey
source§impl Ord for SvcParamKey
impl Ord for SvcParamKey
source§fn cmp(&self, other: &SvcParamKey) -> Ordering
fn cmp(&self, other: &SvcParamKey) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for SvcParamKey
impl PartialEq for SvcParamKey
source§impl PartialOrd for SvcParamKey
impl PartialOrd for SvcParamKey
impl Copy for SvcParamKey
impl Eq for SvcParamKey
impl StructuralPartialEq for SvcParamKey
Auto Trait Implementations§
impl Freeze for SvcParamKey
impl RefUnwindSafe for SvcParamKey
impl Send for SvcParamKey
impl Sync for SvcParamKey
impl Unpin for SvcParamKey
impl UnwindSafe for SvcParamKey
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)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<Source, Target> OctetsInto<Target> for Sourcewhere
Target: OctetsFrom<Source>,
impl<Source, Target> OctetsInto<Target> for Sourcewhere
Target: OctetsFrom<Source>,
type Error = <Target as OctetsFrom<Source>>::Error
source§fn try_octets_into(
self,
) -> Result<Target, <Source as OctetsInto<Target>>::Error>
fn try_octets_into( self, ) -> Result<Target, <Source as OctetsInto<Target>>::Error>
Performs the conversion.
source§fn octets_into(self) -> Target
fn octets_into(self) -> Target
Performs an infallible conversion.