Struct attohttpc::ProxySettingsBuilder
source · [−]pub struct ProxySettingsBuilder { /* private fields */ }
Expand description
Utility to build ProxySettings easily.
Implementations
sourceimpl ProxySettingsBuilder
impl ProxySettingsBuilder
sourcepub fn http_proxy<V>(self, val: V) -> Self where
V: Into<Option<Url>>,
pub fn http_proxy<V>(self, val: V) -> Self where
V: Into<Option<Url>>,
Set the proxy for http requests.
sourcepub fn https_proxy<V>(self, val: V) -> Self where
V: Into<Option<Url>>,
pub fn https_proxy<V>(self, val: V) -> Self where
V: Into<Option<Url>>,
Set the proxy for https requests.
sourcepub fn add_no_proxy_pattern(self, pattern: impl AsRef<str>) -> Self
pub fn add_no_proxy_pattern(self, pattern: impl AsRef<str>) -> Self
Add a hostname pattern to ignore when finding the proxy to use for a URL.
For instance *.mycompany.local
will make every hostname which ends with .mycompany.local
not go trough the proxy.
sourcepub fn build(self) -> ProxySettings
pub fn build(self) -> ProxySettings
Build the settings.
Trait Implementations
sourceimpl Clone for ProxySettingsBuilder
impl Clone for ProxySettingsBuilder
sourcefn clone(&self) -> ProxySettingsBuilder
fn clone(&self) -> ProxySettingsBuilder
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for ProxySettingsBuilder
impl Debug for ProxySettingsBuilder
Auto Trait Implementations
impl RefUnwindSafe for ProxySettingsBuilder
impl Send for ProxySettingsBuilder
impl Sync for ProxySettingsBuilder
impl Unpin for ProxySettingsBuilder
impl UnwindSafe for ProxySettingsBuilder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more