pub struct MessageParts {
pub header: Header,
pub queries: Vec<Query>,
pub answers: Vec<Record>,
pub name_servers: Vec<Record>,
pub additionals: Vec<Record>,
pub sig0: Vec<Record>,
pub edns: Option<Edns>,
}
Expand description
Consumes Message
giving public access to fields in Message
so they can be
destructured and taken by value
use hickory_proto::op::{Message, MessageParts};
let msg = Message::new();
let MessageParts { queries, .. } = msg.into_parts();
Fields§
§header: Header
message header
queries: Vec<Query>
message queries
answers: Vec<Record>
message answers
name_servers: Vec<Record>
message name_servers
additionals: Vec<Record>
message additional records
sig0: Vec<Record>
sig0 or tsig
edns: Option<Edns>
optional edns records
Trait Implementations§
Source§impl Clone for MessageParts
impl Clone for MessageParts
Source§fn clone(&self) -> MessageParts
fn clone(&self) -> MessageParts
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for MessageParts
impl Debug for MessageParts
Source§impl Default for MessageParts
impl Default for MessageParts
Source§fn default() -> MessageParts
fn default() -> MessageParts
Returns the “default value” for a type. Read more
Source§impl From<Message> for MessageParts
impl From<Message> for MessageParts
Source§impl From<MessageParts> for Message
impl From<MessageParts> for Message
Source§fn from(msg: MessageParts) -> Self
fn from(msg: MessageParts) -> Self
Converts to this type from the input type.
Source§impl PartialEq for MessageParts
impl PartialEq for MessageParts
impl Eq for MessageParts
impl StructuralPartialEq for MessageParts
Auto Trait Implementations§
impl Freeze for MessageParts
impl RefUnwindSafe for MessageParts
impl Send for MessageParts
impl Sync for MessageParts
impl Unpin for MessageParts
impl UnwindSafe for MessageParts
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.