pub struct FsStats { /* private fields */ }
Expand description
FsStats
contains some common stats about a file system.
Implementations§
source§impl FsStats
impl FsStats
sourcepub fn free_space(&self) -> u64
pub fn free_space(&self) -> u64
Returns the number of free bytes in the file system containing the provided path.
sourcepub fn available_space(&self) -> u64
pub fn available_space(&self) -> u64
Returns the available space in bytes to non-priveleged users in the file system containing the provided path.
sourcepub fn total_space(&self) -> u64
pub fn total_space(&self) -> u64
Returns the total space in bytes in the file system containing the provided path.
sourcepub fn allocation_granularity(&self) -> u64
pub fn allocation_granularity(&self) -> u64
Returns the filesystem’s disk space allocation granularity in bytes. The provided path may be for any file in the filesystem.
On Posix, this is equivalent to the filesystem’s block size. On Windows, this is equivalent to the filesystem’s cluster size.
Trait Implementations§
source§impl PartialEq<FsStats> for FsStats
impl PartialEq<FsStats> for FsStats
impl Eq for FsStats
impl StructuralEq for FsStats
impl StructuralPartialEq for FsStats
Auto Trait Implementations§
impl RefUnwindSafe for FsStats
impl Send for FsStats
impl Sync for FsStats
impl Unpin for FsStats
impl UnwindSafe for FsStats
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