Struct ra_ap_paths::AbsPath [−][src]
#[repr(transparent)]pub struct AbsPath(_);
Expand description
Wrapper around an absolute Path.
Implementations
Equivalent of Path::parent for AbsPath.
Equivalent of Path::join for AbsPath.
Normalize the given path:
- Removes repeated separators:
/a//bbecomes/a/b - Removes occurrences of
.and resolves... - Removes trailing slashes:
/a/b/becomes/a/b.
Example
let abs_path_buf = AbsPathBuf::assert("/a/../../b/.//c//".into()); let normalized = abs_path_buf.normalize(); assert_eq!(normalized, AbsPathBuf::assert("/b/c".into()));
Equivalent of Path::to_path_buf for AbsPath.
Equivalent of Path::strip_prefix for AbsPath.
Returns a relative path.
Trait Implementations
This method returns an ordering between self and other values if one exists. Read more
This method tests less than (for self and other) and is used by the < operator. Read more
This method tests less than or equal to (for self and other) and is used by the <=
operator. Read more
This method tests greater than (for self and other) and is used by the > operator. Read more
Auto Trait Implementations
impl RefUnwindSafe for AbsPathimpl UnwindSafe for AbsPath