[][src]Struct domain_core::bits::query::OptBuilder

pub struct OptBuilder<'a> { /* fields omitted */ }

A builder for the OPT record of a query.

A mutable reference to this type will be passed to the closure given to QueryBuilder::add_opt. It allows manipulation of the record’s header via the header_mut method and adding of options via push.

Limitations

Note that currently this type is not compatible with the various option types‘ push functions. This will be addressed soon by redesigning that mechanism.

Methods

impl<'a> OptBuilder<'a>[src]

pub fn header(&self) -> &OptHeader[src]

Returns a reference to the header of the OPT record.

pub fn header_mut(&mut self) -> &mut OptHeader[src]

Returns a mutable reference to the header of the OPT record.

pub fn push<O: OptData>(&mut self, option: &O)[src]

Appends an option to the OPT record.

Trait Implementations

impl<'a> Debug for OptBuilder<'a>[src]

Auto Trait Implementations

impl<'a> Send for OptBuilder<'a>

impl<'a> Sync for OptBuilder<'a>

Blanket Implementations

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

impl<T> From for T[src]

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

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

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

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

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

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

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

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