std::path::absolute
pub fn absolute<P: AsRef<Path>>(path: P) -> Result<PathBuf>
- Kind
- function
- Module
std::path- Since
- 1.79.0
Source: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
The entries of std::path in the Rust reference. This page has 91 cards.
pub fn absolute<P: AsRef<Path>>(path: P) -> Result<PathBuf>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub struct Ancestors<'a>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub enum Component<'a>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn as_os_str(self) -> &'a OsStr
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub struct Components<'a>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn as_path(&self) -> &'a Path
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub struct Display<'a>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn is_separator(c: char) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub struct Iter<'a>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn as_path(&self) -> &'a Path
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub const MAIN_SEPARATOR: char = _; // '/'
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub const MAIN_SEPARATOR_STR: &str;
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
#[non_exhaustive]pub struct NormalizeError
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub struct Path
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn absolute(&self) -> Result<PathBuf>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn ancestors(&self) -> Ancestors<'_>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn as_mut_os_str(&mut self) -> &mut OsStr
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn as_os_str(&self) -> &OsStr
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub const fn as_path(&self) -> &Path
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn canonicalize(&self) -> Result<PathBuf>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn components(&self) -> Components<'_>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn display(&self) -> Display<'_>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn ends_with<P: AsRef<Path>>(&self, child: P) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn exists(&self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn extension(&self) -> Option<&OsStr>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn file_name(&self) -> Option<&OsStr>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn file_prefix(&self) -> Option<&OsStr>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn file_stem(&self) -> Option<&OsStr>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn has_root(&self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn has_trailing_sep(&self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn into_path_buf(self: Box<Self>) -> PathBuf
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn is_absolute(&self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn is_dir(&self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn is_empty(&self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn is_file(&self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn is_relative(&self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn is_symlink(&self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn iter(&self) -> Iter<'_>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn join<P: AsRef<Path>>(&self, path: P) -> PathBuf
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn metadata(&self) -> Result<Metadata>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn new<S: AsRef<OsStr> + ?Sized>(s: &S) -> &Path
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn normalize_lexically(&self) -> Result<PathBuf, NormalizeError>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn parent(&self) -> Option<&Path>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn read_dir(&self) -> Result<ReadDir>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn read_link(&self) -> Result<PathBuf>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn starts_with<P: AsRef<Path>>(&self, base: P) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn strip_prefix<P>(&self, base: P) -> Result<&Path, StripPrefixError> where P: AsRef<Path>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn symlink_metadata(&self) -> Result<Metadata>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn to_path_buf(&self) -> PathBuf
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn to_str(&self) -> Option<&str>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn to_string_lossy(&self) -> Cow<'_, str>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn trim_prefix<P>(&self, base: P) -> &Path where P: AsRef<Path>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn trim_trailing_sep(&self) -> &Path
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn try_exists(&self) -> Result<bool>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn with_added_extension<S: AsRef<OsStr>>(&self, extension: S) -> PathBuf
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn with_extension<S: AsRef<OsStr>>(&self, extension: S) -> PathBuf
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn with_file_name<S: AsRef<OsStr>>(&self, file_name: S) -> PathBuf
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn with_trailing_sep(&self) -> Cow<'_, Path>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub struct PathBuf
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn add_extension<S: AsRef<OsStr>>(&mut self, extension: S) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn as_mut_os_string(&mut self) -> &mut OsString
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn as_path(&self) -> &Path
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn capacity(&self) -> usize
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn clear(&mut self)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn into_boxed_path(self) -> Box<Path>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn into_os_string(self) -> OsString
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn into_string(self) -> Result<String, PathBuf>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn leak<'a>(self) -> &'a mut Path
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub const fn new() -> PathBuf
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn pop(&mut self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn pop_trailing_sep(&mut self)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn push<P: AsRef<Path>>(&mut self, path: P)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn push_trailing_sep(&mut self)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn reserve(&mut self, additional: usize)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn reserve_exact(&mut self, additional: usize)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn set_extension<S: AsRef<OsStr>>(&mut self, extension: S) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn set_file_name<S: AsRef<OsStr>>(&mut self, file_name: S)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn set_trailing_sep(&mut self, trailing_sep: bool)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn shrink_to(&mut self, min_capacity: usize)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn shrink_to_fit(&mut self)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn try_reserve(&mut self, additional: usize) -> Result<(), TryReserveError>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn try_reserve_exact( &mut self, additional: usize, ) -> Result<(), TryReserveError>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn with_capacity(capacity: usize) -> PathBuf
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub enum Prefix<'a>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn is_verbatim(&self) -> bool
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub struct PrefixComponent<'a>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn as_os_str(&self) -> &'a OsStr
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub fn kind(&self) -> Prefix<'a>
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub const SEPARATORS: &[char];
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub const SEPARATORS_STR: &[&str];
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.
pub struct StripPrefixError(/* private fields */)
std::pathSource: doc.rust-lang.org, doc.rust-lang.org. JSON record. This entry is a card. Help write this page.