Struct async_std_resolver::lookup_ip::LookupIp [−][src]
Result of a DNS query when querying for A or AAAA records.
When resolving IP records, there can be many IPs that match a given name. A consumer of this should expect that there are more than a single address potentially returned. Generally there are multiple IPs stored for a given service in DNS so that there is a form of high availability offered for a given name. The service implementation is responsible for the semantics around which IP should be used and when, but in general if a connection fails to one, the next in the list should be attempted.
Implementations
impl LookupIp
[src][−]
pub fn iter(&self) -> LookupIpIter<'_>ⓘNotable traits for LookupIpIter<'i>
impl<'i> Iterator for LookupIpIter<'i> type Item = IpAddr;
[src][−]
Notable traits for LookupIpIter<'i>
impl<'i> Iterator for LookupIpIter<'i> type Item = IpAddr;
Returns a borrowed iterator of the returned IPs
pub fn query(&self) -> &Query
[src][−]
Returns a reference to the Query
that was used to produce this result.
pub fn valid_until(&self) -> Instant
[src][−]
Returns the Instant
at which this lookup is no longer valid.
pub fn as_lookup(&self) -> &Lookup
[src][−]
Return a reference to the inner lookup
This can be useful for getting all records from the request
Trait Implementations
impl Clone for LookupIp
[src][+]
impl Debug for LookupIp
[src][+]
impl From<Lookup> for LookupIp
[src][+]
impl From<LookupIp> for Lookup
[src][+]
impl IntoIterator for LookupIp
[src][+]
Auto Trait Implementations
impl RefUnwindSafe for LookupIp
impl Send for LookupIp
impl Sync for LookupIp
impl Unpin for LookupIp
impl UnwindSafe for LookupIp
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src][+]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> From<T> for T
[src][+]
impl<T, U> Into<U> for T where
U: From<T>,
[src][+]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src][+]
T: Clone,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src][+]
U: Into<T>,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src][+]
U: TryFrom<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
[+]
V: MultiLane<T>,