Struct wasi_common::fs::DirEntry
source · pub struct DirEntry {}
Expand description
Entries returned by the ReadDir iterator.
This corresponds to std::fs::DirEntry
.
Unlike std::fs::DirEntry
, this API has no DirEntry::path
, because
absolute paths don’t interoperate well with the capability-oriented
security model.
TODO: Not yet implemented.
Implementations§
source§impl DirEntry
impl DirEntry
sourcepub fn metadata(&self) -> Result<Metadata>
pub fn metadata(&self) -> Result<Metadata>
Returns the metadata for the file that this entry points at.
This corresponds to std::fs::DirEntry::metadata
.
TODO: Not yet implemented.
sourcepub fn file_type(&self) -> Result<FileType>
pub fn file_type(&self) -> Result<FileType>
Returns the file type for the file that this entry points at.
This to std::fs::DirEntry::file_type
.
TODO: Not yet implemented.
sourcepub fn file_name(&self) -> String
pub fn file_name(&self) -> String
Returns the bare file name of this directory entry without any other leading path component.
This corresponds to std::fs::DirEntry::file_name
, though it returns
String
rather than OsString
.
TODO: Not yet implemented.
Auto Trait Implementations§
impl Freeze for DirEntry
impl RefUnwindSafe for DirEntry
impl Send for DirEntry
impl Sync for DirEntry
impl Unpin for DirEntry
impl UnwindSafe for DirEntry
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