pub struct OnDiskDirEntry<'a> { /* private fields */ }
Expand description
A 32-byte directory entry as stored on-disk in a directory file.
This is the same for FAT16 and FAT32 (except FAT16 doesn’t use first_cluster_hi).
Implementations§
Source§impl<'a> OnDiskDirEntry<'a>
impl<'a> OnDiskDirEntry<'a>
Sourcepub fn create_time(&self) -> u16
pub fn create_time(&self) -> u16
Get the value from the $name field
Sourcepub fn create_date(&self) -> u16
pub fn create_date(&self) -> u16
Get the value from the $name field
Sourcepub fn last_access_data(&self) -> u16
pub fn last_access_data(&self) -> u16
Get the value from the $name field
Sourcepub fn first_cluster_hi(&self) -> u16
pub fn first_cluster_hi(&self) -> u16
Get the value from the $name field
Sourcepub fn write_time(&self) -> u16
pub fn write_time(&self) -> u16
Get the value from the $name field
Sourcepub fn write_date(&self) -> u16
pub fn write_date(&self) -> u16
Get the value from the $name field
Sourcepub fn first_cluster_lo(&self) -> u16
pub fn first_cluster_lo(&self) -> u16
Get the value from the $name field
Sourcepub fn new(data: &[u8]) -> OnDiskDirEntry<'_>
pub fn new(data: &[u8]) -> OnDiskDirEntry<'_>
Create a new on-disk directory entry from a block of 32 bytes read from a directory file.
Sourcepub fn lfn_contents(&self) -> Option<(bool, u8, [char; 13])>
pub fn lfn_contents(&self) -> Option<(bool, u8, [char; 13])>
If this is an LFN, get the contents so we can re-assemble the filename.
Sourcepub fn matches(&self, sfn: &ShortFileName) -> bool
pub fn matches(&self, sfn: &ShortFileName) -> bool
Does this on-disk entry match the given filename?
Sourcepub fn first_cluster_fat32(&self) -> ClusterId
pub fn first_cluster_fat32(&self) -> ClusterId
Which cluster, if any, does this file start at? Assumes this is from a FAT32 volume.
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for OnDiskDirEntry<'a>
impl<'a> RefUnwindSafe for OnDiskDirEntry<'a>
impl<'a> Send for OnDiskDirEntry<'a>
impl<'a> Sync for OnDiskDirEntry<'a>
impl<'a> Unpin for OnDiskDirEntry<'a>
impl<'a> UnwindSafe for OnDiskDirEntry<'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