#[non_exhaustive]pub enum ParseUrlError {
NotHttp,
NotLoopback,
InvalidPort,
UserInfo,
InvalidPath,
}Expand description
The reasons a URL is refused by LoopbackUrl.
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.
NotHttp
The URL does not start with http://. Step 1 has no TLS.
NotLoopback
The host is not a canonical IPv4 address in 127.0.0.0/8, [::1]
or localhost.
InvalidPort
The port is not a number from 1 to 65535.
UserInfo
The URL carries user information (user@host).
InvalidPath
The path holds a query, fragment, percent sign, space or control character.
Trait Implementations§
Source§impl Clone for ParseUrlError
impl Clone for ParseUrlError
impl Copy for ParseUrlError
Source§impl Debug for ParseUrlError
impl Debug for ParseUrlError
Source§impl Display for ParseUrlError
impl Display for ParseUrlError
impl Eq for ParseUrlError
Source§impl Error for ParseUrlError
impl Error for ParseUrlError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for ParseUrlError
impl PartialEq for ParseUrlError
impl StructuralPartialEq for ParseUrlError
Auto Trait Implementations§
impl Forget for ParseUrlError
impl Freeze for ParseUrlError
impl Move for ParseUrlError
impl RefUnwindSafe for ParseUrlError
impl Send for ParseUrlError
impl Sync for ParseUrlError
impl Unpin for ParseUrlError
impl UnsafeUnpin for ParseUrlError
impl UnwindSafe for ParseUrlError
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.