Struct resolve::message::Message [] [src]

pub struct Message<'a> {
    pub header: Header,
    pub question: Vec<Question>,
    pub answer: Vec<Resource<'a>>,
    pub authority: Vec<Resource<'a>>,
    pub additional: Vec<Resource<'a>>,
}

Represents a DNS message.

Fields

Describes the content of the remainder of the message.

Carries the question of query type messages.

Resource records that answer the query

Resource records that point to an authoritative name server

Resource records that relate to the query, but are not strictly answers for the question.

Methods

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

[src]

Constructs a new Message with a random id value.

[src]

Constructs a new Message with the given id value.

[src]

Decodes a message from a series of bytes.

[src]

Encodes a message to a series of bytes. On success, returns a subslice of the given buffer containing only the encoded message bytes.

[src]

Returns a DnsError if the message response code is an error.

[src]

Returns an iterator over the records in this message.

[src]

Consumes the message and returns an iterator over its records.

Trait Implementations

impl<'a> Clone for Message<'a>
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

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

[src]

Formats the value using the given formatter.

impl<'a> Default for Message<'a>
[src]

[src]

Returns the "default value" for a type. Read more

impl<'a> Eq for Message<'a>
[src]

impl<'a> PartialEq for Message<'a>
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

[src]

This method tests for !=.