mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-30 04:27:45 +00:00
df: add documentation comments for filesystem.rs
This commit is contained in:
parent
2fac674317
commit
b81f4ef6a7
1 changed files with 15 additions and 0 deletions
|
@ -2,6 +2,11 @@
|
||||||
// *
|
// *
|
||||||
// * For the full copyright and license information, please view the LICENSE
|
// * For the full copyright and license information, please view the LICENSE
|
||||||
// * file that was distributed with this source code.
|
// * file that was distributed with this source code.
|
||||||
|
//! Provides a summary representation of a filesystem.
|
||||||
|
//!
|
||||||
|
//! A [`Filesystem`] struct represents a device containing a
|
||||||
|
//! filesystem mounted at a particular directory. It also includes
|
||||||
|
//! information on amount of space available and amount of space used.
|
||||||
#[cfg(windows)]
|
#[cfg(windows)]
|
||||||
use std::path::Path;
|
use std::path::Path;
|
||||||
|
|
||||||
|
@ -9,9 +14,19 @@ use std::path::Path;
|
||||||
use uucore::fsext::statfs;
|
use uucore::fsext::statfs;
|
||||||
use uucore::fsext::{FsUsage, MountInfo};
|
use uucore::fsext::{FsUsage, MountInfo};
|
||||||
|
|
||||||
|
/// Summary representation of a filesystem.
|
||||||
|
///
|
||||||
|
/// A [`Filesystem`] struct represents a device containing a
|
||||||
|
/// filesystem mounted at a particular directory. The
|
||||||
|
/// [`Filesystem::mount_info`] field exposes that information. The
|
||||||
|
/// [`Filesystem::usage`] field provides information on the amount of
|
||||||
|
/// space available on the filesystem and the amount of space used.
|
||||||
#[derive(Debug, Clone)]
|
#[derive(Debug, Clone)]
|
||||||
pub(crate) struct Filesystem {
|
pub(crate) struct Filesystem {
|
||||||
|
/// Information about the mounted device, mount directory, and related options.
|
||||||
pub mount_info: MountInfo,
|
pub mount_info: MountInfo,
|
||||||
|
|
||||||
|
/// Information about the amount of space used on the filesystem.
|
||||||
pub usage: FsUsage,
|
pub usage: FsUsage,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue