#[non_exhaustive]pub struct FileMetadata {
pub size: u64,
pub allocated: u64,
pub created: u64,
pub modified: u64,
pub accessed: u64,
pub changed: u64,
pub attributes: u32,
pub is_directory: bool,
}Expand description
File/directory metadata carried by a directory entry value.
FILETIME values are the raw 100-ns-since-1601 u64 ticks (UTC), preserved
verbatim so a machine consumer round-trips them losslessly; higher layers
convert to a calendar time.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.size: u64Logical file size in bytes (0 for a directory).
allocated: u64Allocated / reserved size in bytes (0 for a directory).
created: u64Creation FILETIME.
modified: u64Last-modification (last-written) FILETIME.
accessed: u64Last-access FILETIME.
changed: u64Metadata-change (entry last-modification) FILETIME.
attributes: u32File attribute flags (0x10 = directory, 0x20 = archive, …).
is_directory: boolTrue when this entry is a directory.
Trait Implementations§
Source§impl Clone for FileMetadata
impl Clone for FileMetadata
Source§impl Debug for FileMetadata
impl Debug for FileMetadata
impl Eq for FileMetadata
Source§impl PartialEq for FileMetadata
impl PartialEq for FileMetadata
impl StructuralPartialEq for FileMetadata
Auto Trait Implementations§
impl Freeze for FileMetadata
impl RefUnwindSafe for FileMetadata
impl Send for FileMetadata
impl Sync for FileMetadata
impl Unpin for FileMetadata
impl UnsafeUnpin for FileMetadata
impl UnwindSafe for FileMetadata
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