[][src]Struct trust_dns_resolver::Hosts

pub struct Hosts { /* fields omitted */ }

Configuration for the local /etc/hosts

Methods

impl Hosts
[src]

pub fn new() -> Hosts
[src]

Creates a new configuration from /etc/hosts, only works for unix like OSes, others will return empty configuration

pub fn lookup_static_host(&self, query: &Query) -> Option<Lookup>
[src]

lookup_static_host looks up the addresses for the given host from /etc/hosts.

pub fn insert(&mut self, name: Name, record_type: RecordType, lookup: Lookup)
[src]

Insert a new Lookup for the associated Name and RecordType

Trait Implementations

impl Default for Hosts
[src]

impl Debug for Hosts
[src]

Auto Trait Implementations

impl Send for Hosts

impl Sync for Hosts

Blanket Implementations

impl<T> From for T
[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Erased for T