#[non_exhaustive]pub enum ProxySetting {
Unset,
Disabled,
Url(Url),
Raw(String),
}Expand description
Proxy configuration for a repository.
Can be unset (use system default), explicitly disabled, a specific proxy URL, or a raw unparseable string.
§Examples
use dnf_repofile::ProxySetting;
let disabled = ProxySetting::Disabled;
let url_proxy = ProxySetting::Url("http://proxy:8080/".parse().unwrap());Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Unset
Use the default proxy configuration (no explicit setting).
Disabled
Explicitly disable proxy (proxy=_none_).
Url(Url)
Use this specific proxy URL.
Raw(String)
A proxy value that could not be parsed as a valid URL (preserved for round-trip fidelity).
Trait Implementations§
Source§impl Clone for ProxySetting
impl Clone for ProxySetting
Source§fn clone(&self) -> ProxySetting
fn clone(&self) -> ProxySetting
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ProxySetting
impl Debug for ProxySetting
Source§impl PartialEq for ProxySetting
impl PartialEq for ProxySetting
Source§fn eq(&self, other: &ProxySetting) -> bool
fn eq(&self, other: &ProxySetting) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for ProxySetting
impl StructuralPartialEq for ProxySetting
Auto Trait Implementations§
impl Freeze for ProxySetting
impl RefUnwindSafe for ProxySetting
impl Send for ProxySetting
impl Sync for ProxySetting
impl Unpin for ProxySetting
impl UnsafeUnpin for ProxySetting
impl UnwindSafe for ProxySetting
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.