pub struct Https<O, N> { /* private fields */ }
Expand description
Struct has priority and target decoded, but not parameters.
Provides a iter
method to iterate through each parameter.
Implementations
sourceimpl<O, N> Https<O, N>
impl<O, N> Https<O, N>
sourcepub fn new(priority: u16, target: N, params: O) -> Self
pub fn new(priority: u16, target: N, params: O) -> Self
Create a new SVCB(or its siblings) with given arguments.
Examples
To parse a SVCB record
ⓘ
let rdata = SVCB::new(1, dname, octets);
for param in rdata.iter() {
...
}
To build a SCVB record
ⓘ
let rdata = SCVB::new(1, dname, octets_builder);
rdata.push(param1)?;
rdata.push(param2)?;
rdata.freeze();
sourceimpl<OB: OctetsBuilder, N> Https<OB, N>
impl<OB: OctetsBuilder, N> Https<OB, N>
sourceimpl<OB: OctetsBuilder + AsMut<[u8]>, N> Https<OB, N>
impl<OB: OctetsBuilder + AsMut<[u8]>, N> Https<OB, N>
Trait Implementations
sourceimpl<O: AsRef<[u8]>, N: Compose> Compose for Https<O, N>
impl<O: AsRef<[u8]>, N: Compose> Compose for Https<O, N>
sourcefn compose<T: OctetsBuilder + AsMut<[u8]>>(
&self,
target: &mut T
) -> Result<(), ShortBuf>
fn compose<T: OctetsBuilder + AsMut<[u8]>>(
&self,
target: &mut T
) -> Result<(), ShortBuf>
Appends the concrete representation of the value to the target. Read more
sourcefn compose_canonical<T: OctetsBuilder + AsMut<[u8]>>(
&self,
target: &mut T
) -> Result<(), ShortBuf>
fn compose_canonical<T: OctetsBuilder + AsMut<[u8]>>(
&self,
target: &mut T
) -> Result<(), ShortBuf>
Appends the canonical representation of the value to the target. Read more
sourceimpl<O, N> From<Https<O, N>> for AllRecordData<O, N>
impl<O, N> From<Https<O, N>> for AllRecordData<O, N>
sourceimpl<O, OO, N, NN> OctetsFrom<Https<O, N>> for Https<OO, NN>where
OO: OctetsFrom<O>,
NN: OctetsFrom<N>,
impl<O, OO, N, NN> OctetsFrom<Https<O, N>> for Https<OO, NN>where
OO: OctetsFrom<O>,
NN: OctetsFrom<N>,
sourcefn octets_from(source: Https<O, N>) -> Result<Self, ShortBuf>
fn octets_from(source: Https<O, N>) -> Result<Self, ShortBuf>
Performs the conversion.
sourceimpl<O, OO, N, NN> PartialEq<Https<OO, NN>> for Https<O, N>where
O: AsRef<[u8]>,
OO: AsRef<[u8]>,
N: ToDname,
NN: ToDname,
impl<O, OO, N, NN> PartialEq<Https<OO, NN>> for Https<O, N>where
O: AsRef<[u8]>,
OO: AsRef<[u8]>,
N: ToDname,
NN: ToDname,
sourceimpl<O, N> RtypeRecordData for Https<O, N>
impl<O, N> RtypeRecordData for Https<O, N>
impl<O: AsRef<[u8]>, N: ToDname> Eq for Https<O, N>
Auto Trait Implementations
impl<O, N> RefUnwindSafe for Https<O, N>where
N: RefUnwindSafe,
O: RefUnwindSafe,
impl<O, N> Send for Https<O, N>where
N: Send,
O: Send,
impl<O, N> Sync for Https<O, N>where
N: Sync,
O: Sync,
impl<O, N> Unpin for Https<O, N>where
N: Unpin,
O: Unpin,
impl<O, N> UnwindSafe for Https<O, N>where
N: UnwindSafe,
O: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<Source, Target> OctetsInto<Target> for Sourcewhere
Target: OctetsFrom<Source>,
impl<Source, Target> OctetsInto<Target> for Sourcewhere
Target: OctetsFrom<Source>,
sourcefn octets_into(self) -> Result<Target, ShortBuf>
fn octets_into(self) -> Result<Target, ShortBuf>
Performs the conversion.
sourceimpl<Octets, T> ParseRecordData<Octets> for Twhere
T: RtypeRecordData + Parse<Octets> + Compose,
impl<Octets, T> ParseRecordData<Octets> for Twhere
T: RtypeRecordData + Parse<Octets> + Compose,
sourcefn parse_data(
rtype: Rtype,
parser: &mut Parser<Octets>
) -> Result<Option<T>, ParseError>
fn parse_data(
rtype: Rtype,
parser: &mut Parser<Octets>
) -> Result<Option<T>, ParseError>
Parses the record data. Read more