pub trait MetadataExt {
// Required methods
fn dev(&self) -> u64;
fn ino(&self) -> u64;
fn nlink(&self) -> u64;
}Expand description
Extension trait for Metadata.
Required Methods§
Sourcefn dev(&self) -> u64
fn dev(&self) -> u64
Returns the ID of the device containing the file.
This corresponds to std::os::unix::fs::MetadataExt::dev, except
that it’s supported on Windows platforms as well.
Sourcefn ino(&self) -> u64
fn ino(&self) -> u64
Returns the inode number.
This corresponds to std::os::unix::fs::MetadataExt::ino, except
that it’s supported on Windows platforms as well.
FIXME: On Windows’ ReFS, file identifiers are 128-bit.
Sourcefn nlink(&self) -> u64
fn nlink(&self) -> u64
Returns the number of hard links pointing to this file.
This corresponds to std::os::unix::fs::MetadataExt::nlink, except
that it’s supported on Windows platforms as well.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementations on Foreign Types§
Source§impl MetadataExt for Metadata
Available on non-Windows only.
impl MetadataExt for Metadata
Available on non-Windows only.
Implementors§
impl MetadataExt for cap_fs_ext::Metadata
Available on crate feature
std and non-Windows only.