pub struct Metadata(_);
Available on crate feature
fs
only.Expand description
Metadata information about a file.
Implementations§
source§impl Metadata
impl Metadata
sourcepub const fn file_type(&self) -> VfsNodeType
pub const fn file_type(&self) -> VfsNodeType
Returns the file type for this metadata.
sourcepub const fn is_dir(&self) -> bool
pub const fn is_dir(&self) -> bool
Returns true
if this metadata is for a directory. The
result is mutually exclusive to the result of
Metadata::is_file
.
sourcepub const fn is_file(&self) -> bool
pub const fn is_file(&self) -> bool
Returns true
if this metadata is for a regular file. The
result is mutually exclusive to the result of
Metadata::is_dir
.
sourcepub fn permissions(&self) -> VfsNodePerm
pub fn permissions(&self) -> VfsNodePerm
Returns the permissions of the file this metadata is for.
sourcepub const fn raw_metadata(&self) -> &VfsNodeAttr
pub const fn raw_metadata(&self) -> &VfsNodeAttr
Returns the inner raw metadata fops::FileAttr
.
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Metadata
impl Send for Metadata
impl Sync for Metadata
impl Unpin for Metadata
impl UnwindSafe for Metadata
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