pub struct DirEntries<'a> { /* private fields */ }Expand description
Represents a collection of entries in a directory.
This type provides access to the files and subdirectories within a directory. It can be iterated over or queried by name.
Implementations§
Source§impl<'a> DirEntries<'a>
impl<'a> DirEntries<'a>
Sourcepub fn get(&self, name: &[u8]) -> Option<&DirEntry<'a>>
pub fn get(&self, name: &[u8]) -> Option<&DirEntry<'a>>
Returns a reference to the entry with the given name.
Sourcepub fn remove(&mut self, name: &[u8]) -> Option<DirEntry<'a>>
pub fn remove(&mut self, name: &[u8]) -> Option<DirEntry<'a>>
Removes and returns the entry with the given name.
Sourcepub fn iter(&self) -> DirEntriesIter<'_, 'a> ⓘ
pub fn iter(&self) -> DirEntriesIter<'_, 'a> ⓘ
Returns an iterator over the entries.
Trait Implementations§
Source§impl<'a> Debug for DirEntries<'a>
impl<'a> Debug for DirEntries<'a>
Source§impl<'b, 'a> IntoIterator for &'b DirEntries<'a>
impl<'b, 'a> IntoIterator for &'b DirEntries<'a>
Source§impl<'a> IntoIterator for DirEntries<'a>
impl<'a> IntoIterator for DirEntries<'a>
Auto Trait Implementations§
impl<'a> Freeze for DirEntries<'a>
impl<'a> !RefUnwindSafe for DirEntries<'a>
impl<'a> Send for DirEntries<'a>
impl<'a> Sync for DirEntries<'a>
impl<'a> Unpin for DirEntries<'a>
impl<'a> !UnwindSafe for DirEntries<'a>
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