#[non_exhaustive]pub enum PathSegmentError {
InvalidUtf8 {
segment: Vec<u8>,
},
IllegalPathComponent(String),
InvalidCharacter(char),
Empty,
NotAbsolute,
}
Expand description
An error that may occur while parsing a PathSegment
or PathSegments
.
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.
InvalidUtf8
The segment wasn’t valid UTF-8.
IllegalPathComponent(String)
Found a path segment that isn’t allowed.
InvalidCharacter(char)
Found a path segment containing illegal characters.
Empty
The path segment was empty.
NotAbsolute
The path wasn’t absolute.
Trait Implementations§
source§impl Clone for PathSegmentError
impl Clone for PathSegmentError
source§fn clone(&self) -> PathSegmentError
fn clone(&self) -> PathSegmentError
Returns a copy of the value. Read more
1.0.0 · 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 PathSegmentError
impl Debug for PathSegmentError
source§impl Display for PathSegmentError
impl Display for PathSegmentError
source§impl Error for PathSegmentError
impl Error for PathSegmentError
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 From<PathSegmentError> for ContainerError
impl From<PathSegmentError> for ContainerError
source§fn from(source: PathSegmentError) -> Self
fn from(source: PathSegmentError) -> Self
Converts to this type from the input type.
source§impl From<PathSegmentError> for LookupError
Available on crate feature v2
only.
impl From<PathSegmentError> for LookupError
Available on crate feature
v2
only.source§fn from(source: PathSegmentError) -> Self
fn from(source: PathSegmentError) -> Self
Converts to this type from the input type.
source§impl From<PathSegmentError> for LookupError
Available on crate feature v3
only.
impl From<PathSegmentError> for LookupError
Available on crate feature
v3
only.source§fn from(source: PathSegmentError) -> Self
fn from(source: PathSegmentError) -> Self
Converts to this type from the input type.
source§impl From<PathSegmentError> for VolumeError
impl From<PathSegmentError> for VolumeError
source§fn from(source: PathSegmentError) -> Self
fn from(source: PathSegmentError) -> Self
Converts to this type from the input type.
source§impl PartialEq for PathSegmentError
impl PartialEq for PathSegmentError
impl StructuralPartialEq for PathSegmentError
Auto Trait Implementations§
impl Freeze for PathSegmentError
impl RefUnwindSafe for PathSegmentError
impl Send for PathSegmentError
impl Sync for PathSegmentError
impl Unpin for PathSegmentError
impl UnwindSafe for PathSegmentError
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)