Struct domain::rdata::rfc1035::Mx
[−]
[src]
pub struct Mx<N: DName> { /* fields omitted */ }
Mx record data.
The Mx record specifies a host willing to serve as a mail exchange for the owner name.
The Mx record type is defined in RFC 1035, section 3.3.9.
Methods
impl<N: DName> Mx<N>
[src]
fn new(preference: u16, exchange: N) -> Self
Creates a new Mx record data from the components.
fn preference(&self) -> u16
The preference for this record.
Defines an order if there are several Mx records for the same owner. Lower values are preferred.
fn exchange(&self) -> &N
The name of the host that is the exchange.
impl Mx<DNameBuf>
[src]
fn scan<S: Scanner>(
scanner: &mut S,
origin: Option<&DNameSlice>
) -> ScanResult<Self>
scanner: &mut S,
origin: Option<&DNameSlice>
) -> ScanResult<Self>
Trait Implementations
impl<N: Clone + DName> Clone for Mx<N>
[src]
fn clone(&self) -> Mx<N>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl<N: Debug + DName> Debug for Mx<N>
[src]
impl<N: Eq + DName> Eq for Mx<N>
[src]
impl<N: Ord + DName> Ord for Mx<N>
[src]
fn cmp(&self, __arg_0: &Mx<N>) -> Ordering
This method returns an Ordering
between self
and other
. Read more
impl<N: PartialEq + DName> PartialEq for Mx<N>
[src]
fn eq(&self, __arg_0: &Mx<N>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Mx<N>) -> bool
This method tests for !=
.
impl<N: PartialOrd + DName> PartialOrd for Mx<N>
[src]
fn partial_cmp(&self, __arg_0: &Mx<N>) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, __arg_0: &Mx<N>) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, __arg_0: &Mx<N>) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, __arg_0: &Mx<N>) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, __arg_0: &Mx<N>) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl<N: DName> RecordData for Mx<N>
[src]
fn rtype(&self) -> Rtype
Returns the record type for this record data instance. Read more
fn compose<C: AsMut<Composer>>(&self, target: C) -> ComposeResult<()>
Appends the record data to the end of a composer.
impl<'a> ParsedRecordData<'a> for Mx<ParsedDName<'a>>
[src]
fn parse(rtype: Rtype, parser: &mut Parser<'a>) -> ParseResult<Option<Self>>
Parses the record data out of a parser.