Struct iref::PathMut [−][src]
pub struct PathMut<'a> { /* fields omitted */ }
Implementations
Checks if the path is empty.
Returns true
if the path is `` or /
.
Checks if the path is absolute.
A path is absolute if it starts with a /
.
A path is necessarily absolute if the IRI it is contained in contains a non-empty
authority.
Checks if the path is relative.
A path is relative if it does not start with a /
.
A path cannot be relative if the IRI it is contained in contains a non-empty authority.
Make sure the last segment is followed by a /
.
This has no effect if the path is empty.
Produces an iterator over the segments of the IRI path.
Note that this is an IRI path, not an IRI reference path: no normalization occurs with
.
and ..
segments. This is done by the IRI reference resolution function.
Empty segments are preserved: the path a//b
will raise the three segments a
, and `b`. The absolute path `/` has no segments, but the path `/a/` has two segments, `a` and
.
pub fn normalized_segments(&self) -> NormalizedSegments<'_>ⓘNotable traits for NormalizedSegments<'a>impl<'a> Iterator for NormalizedSegments<'a> type Item = Segment<'a>;
impl<'a> Iterator for NormalizedSegments<'a> type Item = Segment<'a>;