Struct attohttpc::ProxySettings[][src]

pub struct ProxySettings { /* fields omitted */ }

Contains proxy settings and utilities to find which proxy to use for a given URL.

Implementations

impl ProxySettings[src]

pub fn builder() -> ProxySettingsBuilder[src]

Get a new builder for ProxySettings.

pub fn from_env() -> ProxySettings[src]

Get the proxy configuration from the environment using the curl/Unix proxy conventions.

Only HTTP_PROXY, HTTPS_PROXY and NO_PROXY are supported. NO_PROXY supports wildcard patterns.

pub fn for_url(&self, url: &Url) -> Option<&Url>[src]

Get the proxy URL to use for the given URL.

None is returned if there is no proxy configured for the scheme or if the hostname matches a pattern in the no proxy list.

Trait Implementations

impl Clone for ProxySettings[src]

impl Debug for ProxySettings[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

impl<T> CloneAny for T where
    T: Clone + Any

impl<T> DebugAny for T where
    T: Any + Debug

impl<T> From<T> for T[src]

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

The type returned in the event of a conversion error.

impl<T> Typeable for T where
    T: Any

impl<T> UnsafeAny for T where
    T: Any

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,