Enum trust_dns_server::authority::LookupRecords
source · [−]pub enum LookupRecords {
Empty,
Records {
lookup_options: LookupOptions,
records: Arc<RecordSet>,
},
ManyRecords(LookupOptions, Vec<Arc<RecordSet>>),
AnyRecords(AnyRecords),
}
Expand description
The result of a lookup
Variants
Empty
The empty set of records
Records
Fields
lookup_options: LookupOptions
LookupOptions for the request, e.g. dnssec and supported algorithms
The associate records
ManyRecords(LookupOptions, Vec<Arc<RecordSet>>)
Vec of disjoint record sets
AnyRecords(AnyRecords)
A generic lookup response where anything is desired
Implementations
sourceimpl LookupRecords
impl LookupRecords
sourcepub fn new(lookup_options: LookupOptions, records: Arc<RecordSet>) -> Self
pub fn new(lookup_options: LookupOptions, records: Arc<RecordSet>) -> Self
Construct a new LookupRecords
sourcepub fn many(lookup_options: LookupOptions, records: Vec<Arc<RecordSet>>) -> Self
pub fn many(lookup_options: LookupOptions, records: Vec<Arc<RecordSet>>) -> Self
Construct a new LookupRecords over a set of ResordSets
sourcepub fn was_empty(&self) -> bool
pub fn was_empty(&self) -> bool
This is an NxDomain or NameExists, and has no associated records
this consumes the iterator, and verifies it is empty
sourcepub fn iter(&self) -> LookupRecordsIter<'_>ⓘNotable traits for LookupRecordsIter<'r>impl<'r> Iterator for LookupRecordsIter<'r> type Item = &'r Record;
pub fn iter(&self) -> LookupRecordsIter<'_>ⓘNotable traits for LookupRecordsIter<'r>impl<'r> Iterator for LookupRecordsIter<'r> type Item = &'r Record;
Conversion to an iterator
Trait Implementations
sourceimpl Debug for LookupRecords
impl Debug for LookupRecords
sourceimpl Default for LookupRecords
impl Default for LookupRecords
sourceimpl From<AnyRecords> for LookupRecords
impl From<AnyRecords> for LookupRecords
sourcefn from(rrset_records: AnyRecords) -> Self
fn from(rrset_records: AnyRecords) -> Self
Performs the conversion.
sourceimpl From<LookupRecords> for AuthLookup
impl From<LookupRecords> for AuthLookup
sourcefn from(lookup: LookupRecords) -> Self
fn from(lookup: LookupRecords) -> Self
Performs the conversion.
sourceimpl<'a> IntoIterator for &'a LookupRecords
impl<'a> IntoIterator for &'a LookupRecords
sourceimpl LookupObject for LookupRecords
impl LookupObject for LookupRecords
sourcefn is_empty(&self) -> bool
fn is_empty(&self) -> bool
Returns true if either the associated Records are empty, or this is a NameExists or NxDomain
sourcefn iter<'a>(&'a self) -> Box<dyn Iterator<Item = &'a Record> + Send + 'a>
fn iter<'a>(&'a self) -> Box<dyn Iterator<Item = &'a Record> + Send + 'a>
Conversion to an iterator
sourcefn take_additionals(&mut self) -> Option<Box<dyn LookupObject>>
fn take_additionals(&mut self) -> Option<Box<dyn LookupObject>>
For CNAME and similar records, this is an additional set of lookup records Read more
Auto Trait Implementations
impl RefUnwindSafe for LookupRecords
impl Send for LookupRecords
impl Sync for LookupRecords
impl Unpin for LookupRecords
impl UnwindSafe for LookupRecords
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
pub fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more