[][src]Struct domain::base::message::QuestionSection

pub struct QuestionSection<Ref> { /* fields omitted */ }

An iterator over the question section of a DNS message.

The iterator’s item is the result of trying to parse the question. In case of a parse error, next will return an error once and None after that.

You can create a value of this type through Message::question. Use the answer or next_section methods on a question section to proceed to an iterator over the answer section.

Implementations

impl<Ref: OctetsRef> QuestionSection<Ref>[src]

pub fn pos(&self) -> usize[src]

Returns the current position relative to the beginning of the message.

pub fn answer(self) -> Result<RecordSection<Ref>, ParseError>[src]

Proceeds to the answer section.

Skips over any remaining questions and then converts itself into the first RecordSection.

pub fn next_section(self) -> Result<RecordSection<Ref>, ParseError>[src]

Proceeds to the answer section.

This is identical to [answer] and is here for consistency.

Trait Implementations

impl<Ref: Clone> Clone for QuestionSection<Ref>[src]

impl<Ref: Copy> Copy for QuestionSection<Ref>[src]

impl<Ref: Debug> Debug for QuestionSection<Ref>[src]

impl<Ref: OctetsRef> Iterator for QuestionSection<Ref>[src]

type Item = Result<Question<ParsedDname<Ref>>, ParseError>

The type of the elements being iterated over.

impl<Ref, Other> PartialEq<QuestionSection<Other>> for QuestionSection<Ref> where
    Ref: OctetsRef,
    Other: OctetsRef
[src]

Auto Trait Implementations

impl<Ref> RefUnwindSafe for QuestionSection<Ref> where
    Ref: RefUnwindSafe

impl<Ref> Send for QuestionSection<Ref> where
    Ref: Send

impl<Ref> Sync for QuestionSection<Ref> where
    Ref: Sync

impl<Ref> Unpin for QuestionSection<Ref> where
    Ref: Unpin

impl<Ref> UnwindSafe for QuestionSection<Ref> where
    Ref: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<I> IntoIterator for I where
    I: Iterator
[src]

type Item = <I as Iterator>::Item

The type of the elements being iterated over.

type IntoIter = I

Which kind of iterator are we turning this into?

impl<I> IteratorRandom for I where
    I: Iterator
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,