pub struct DnsQuestions<const PTR_STORAGE: usize, B: Buffer> { /* private fields */ }
Expand description
A DNS message questions section.
Implementations§
Source§impl<const PTR_STORAGE: usize, B: Buffer> DnsQuestions<PTR_STORAGE, B>
impl<const PTR_STORAGE: usize, B: Buffer> DnsQuestions<PTR_STORAGE, B>
Sourcepub fn iter(&mut self) -> Result<DnsQuestionIterator<'_>, DnsMessageError>
pub fn iter(&mut self) -> Result<DnsQuestionIterator<'_>, DnsMessageError>
Return an iterator over the question section.
Sourcepub fn complete(self) -> Result<DnsMessage<PTR_STORAGE, 1, B>, DnsMessageError>
pub fn complete(self) -> Result<DnsMessage<PTR_STORAGE, 1, B>, DnsMessageError>
Complete the message. This will check the remaining questions and return the message if successful.
Source§impl<const PTR_STORAGE: usize, B: MutBuffer + Buffer> DnsQuestions<PTR_STORAGE, B>
impl<const PTR_STORAGE: usize, B: MutBuffer + Buffer> DnsQuestions<PTR_STORAGE, B>
Sourcepub fn append(
&mut self,
question: DnsQuestion<'_>,
) -> Result<(), DnsMessageError>
pub fn append( &mut self, question: DnsQuestion<'_>, ) -> Result<(), DnsMessageError>
Append a question to the message. This will override the next question or further sections, if any.
Auto Trait Implementations§
impl<const PTR_STORAGE: usize, B> Freeze for DnsQuestions<PTR_STORAGE, B>where
B: Freeze,
impl<const PTR_STORAGE: usize, B> RefUnwindSafe for DnsQuestions<PTR_STORAGE, B>where
B: RefUnwindSafe,
impl<const PTR_STORAGE: usize, B> Send for DnsQuestions<PTR_STORAGE, B>where
B: Send,
impl<const PTR_STORAGE: usize, B> Sync for DnsQuestions<PTR_STORAGE, B>where
B: Sync,
impl<const PTR_STORAGE: usize, B> Unpin for DnsQuestions<PTR_STORAGE, B>where
B: Unpin,
impl<const PTR_STORAGE: usize, B> UnwindSafe for DnsQuestions<PTR_STORAGE, B>where
B: UnwindSafe,
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