pub enum PathBufDyn {
Os(PathBuf),
Unix(UnixPathBuf),
}Variants§
Os(PathBuf)
Unix(UnixPathBuf)
Implementations§
Source§impl PathBufDyn
impl PathBufDyn
pub unsafe fn from_encoded_bytes<K>(kind: K, bytes: Vec<u8>) -> Self
pub fn from_components<'a, K, I>(kind: K, iter: I) -> Result<Self, PathDynError>
pub fn into_encoded_bytes(self) -> Vec<u8> ⓘ
pub fn into_os(self) -> Result<PathBuf, PathDynError>
pub fn into_unix(self) -> Result<UnixPathBuf, PathDynError>
pub fn new(kind: PathKind) -> Self
pub fn try_extend<T>(&mut self, paths: T) -> Result<(), PathDynError>
pub fn try_push<T>(&mut self, path: T) -> Result<(), PathDynError>where
T: AsPath,
pub fn try_set_name<T>(&mut self, name: T) -> Result<(), SetNameError>where
T: AsStrand,
pub fn with<K>(kind: K, bytes: Vec<u8>) -> Result<Self, PathDynError>
pub fn with_capacity<K>(kind: K, capacity: usize) -> Self
pub fn with_str<K, S>(kind: K, s: S) -> Self
Trait Implementations§
Source§impl Clone for PathBufDyn
impl Clone for PathBufDyn
Source§fn clone(&self) -> PathBufDyn
fn clone(&self) -> PathBufDyn
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 PathBufDyn
impl Debug for PathBufDyn
impl Eq for PathBufDyn
Source§impl Equivalent<PathBufDyn> for PathDyn<'_>
impl Equivalent<PathBufDyn> for PathDyn<'_>
Source§fn equivalent(&self, key: &PathBufDyn) -> bool
fn equivalent(&self, key: &PathBufDyn) -> bool
Compare self to
key and return true if they are equal.Source§impl Equivalent<PathDyn<'_>> for PathBufDyn
impl Equivalent<PathDyn<'_>> for PathBufDyn
Source§fn equivalent(&self, key: &PathDyn<'_>) -> bool
fn equivalent(&self, key: &PathDyn<'_>) -> bool
Compare self to
key and return true if they are equal.Source§impl<'a> From<&'a PathBufDyn> for PathDyn<'a>
impl<'a> From<&'a PathBufDyn> for PathDyn<'a>
Source§fn from(value: &'a PathBufDyn) -> Self
fn from(value: &'a PathBufDyn) -> Self
Converts to this type from the input type.
Source§impl From<&Path> for PathBufDyn
impl From<&Path> for PathBufDyn
Source§impl From<PathBuf<UnixEncoding>> for PathBufDyn
impl From<PathBuf<UnixEncoding>> for PathBufDyn
Source§fn from(value: UnixPathBuf) -> Self
fn from(value: UnixPathBuf) -> Self
Converts to this type from the input type.
Source§impl From<PathBuf> for PathBufDyn
impl From<PathBuf> for PathBufDyn
Source§impl From<PathBufDyn> for PathCow<'_>
impl From<PathBufDyn> for PathCow<'_>
Source§fn from(value: PathBufDyn) -> Self
fn from(value: PathBufDyn) -> Self
Converts to this type from the input type.
Source§impl From<PathCow<'_>> for PathBufDyn
impl From<PathCow<'_>> for PathBufDyn
Source§impl From<PathDyn<'_>> for PathBufDyn
impl From<PathDyn<'_>> for PathBufDyn
Source§impl Hash for PathBufDyn
impl Hash for PathBufDyn
Source§impl IntoStrand for PathBufDyn
impl IntoStrand for PathBufDyn
fn into_strand(self) -> StrandBuf
Source§impl IntoStrand for &PathBufDyn
impl IntoStrand for &PathBufDyn
fn into_strand(self) -> StrandBuf
Source§impl PartialEq for PathBufDyn
impl PartialEq for PathBufDyn
Source§impl PartialEq<PathBufDyn> for PathDyn<'_>
impl PartialEq<PathBufDyn> for PathDyn<'_>
Source§impl PartialEq<PathDyn<'_>> for PathBufDyn
impl PartialEq<PathDyn<'_>> for PathBufDyn
Source§impl PartialEq<PathDyn<'_>> for &PathBufDyn
impl PartialEq<PathDyn<'_>> for &PathBufDyn
Source§impl PathLike for PathBufDyn
impl PathLike for PathBufDyn
fn as_os(&self) -> Result<&Path, PathDynError>
fn as_unix(&self) -> Result<&UnixPath, PathDynError>
fn components(&self) -> Components<'_> ⓘ
fn display(&self) -> Display<'_>
fn encoded_bytes(&self) -> &[u8] ⓘ
fn ext(&self) -> Option<Strand<'_>>
fn has_root(&self) -> bool
fn is_absolute(&self) -> bool
fn is_empty(&self) -> bool
fn kind(&self) -> PathKind
fn len(&self) -> usize
fn name(&self) -> Option<Strand<'_>>
fn parent(&self) -> Option<PathDyn<'_>>
fn rsplit_pred<T>(&self, pred: T) -> Option<(PathDyn<'_>, PathDyn<'_>)>where
T: Utf8BytePredictor,
fn stem(&self) -> Option<Strand<'_>>
fn to_os_owned(&self) -> Result<PathBuf, PathDynError>
fn to_owned(&self) -> PathBufDyn
fn to_str(&self) -> Result<&str, Utf8Error>
fn to_string_lossy(&self) -> Cow<'_, str>
fn try_ends_with<T>(&self, child: T) -> Result<bool, EndsWithError>where
T: AsStrand,
fn try_join<T>(&self, path: T) -> Result<PathBufDyn, JoinError>where
T: AsStrand,
fn try_rsplit_seq<T>(
&self,
pat: T,
) -> Result<(PathDyn<'_>, PathDyn<'_>), RsplitOnceError>where
T: AsStrand,
fn try_starts_with<T>(&self, base: T) -> Result<bool, StartsWithError>where
T: AsStrand,
fn try_strip_prefix<T>(&self, base: T) -> Result<PathDyn<'_>, StripPrefixError>where
T: AsStrand,
fn try_strip_suffix<T>(
&self,
suffix: T,
) -> Result<PathDyn<'_>, StripSuffixError>where
T: AsStrand,
Source§impl TryFrom<PathBufDyn> for PathBuf
impl TryFrom<PathBufDyn> for PathBuf
Source§type Error = PathDynError
type Error = PathDynError
The type returned in the event of a conversion error.
Source§impl TryFrom<PathBufDyn> for UnixPathBuf
impl TryFrom<PathBufDyn> for UnixPathBuf
Source§type Error = PathDynError
type Error = PathDynError
The type returned in the event of a conversion error.
Auto Trait Implementations§
impl Freeze for PathBufDyn
impl RefUnwindSafe for PathBufDyn
impl Send for PathBufDyn
impl Sync for PathBufDyn
impl Unpin for PathBufDyn
impl UnsafeUnpin for PathBufDyn
impl UnwindSafe for PathBufDyn
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§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more