pub struct Attrs { /* private fields */ }Expand description
Idiomatic metadata returned by the Rust-native path API.
Implementations§
Source§impl Attrs
impl Attrs
Sourcepub fn returned_attributes(&self) -> AttrMask
pub fn returned_attributes(&self) -> AttrMask
Attribute fields actually returned by the backend, not merely requested.
Optional accessors remain None when a field was not requested or the
backend could not provide it. Check this mask before projecting the
metadata into an API that requires concrete values (such as stat).
Sourcepub fn missing_attributes(&self, requested: AttrMask) -> AttrMask
pub fn missing_attributes(&self, requested: AttrMask) -> AttrMask
Requested fields that were not returned by the backend.
Sourcepub fn has_attributes(&self, requested: AttrMask) -> bool
pub fn has_attributes(&self, requested: AttrMask) -> bool
Whether every field in requested was returned by the backend.
Sourcepub fn mode(&self) -> Option<u32>
pub fn mode(&self) -> Option<u32>
Full POSIX mode, including the file type bits, when returned.
Sourcepub fn has_named_attributes(&self) -> Option<bool>
pub fn has_named_attributes(&self) -> Option<bool>
Whether named attributes exist, when the backend supplied this field.
pub fn file_type(&self) -> VfType
pub fn is_file(&self) -> bool
pub fn is_dir(&self) -> bool
pub fn is_symlink(&self) -> bool
Sourcepub fn len(&self) -> Option<u64>
pub fn len(&self) -> Option<u64>
Logical size, when SIZE was returned. Missing is distinct from zero.
pub fn is_empty(&self) -> Option<bool>
Sourcepub fn permissions(&self) -> Option<Permissions>
pub fn permissions(&self) -> Option<Permissions>
Permission bits, when MODE was returned. Missing is distinct from mode zero.
pub fn modified(&self) -> Option<SystemTime>
pub fn accessed(&self) -> Option<SystemTime>
Sourcepub fn changed(&self) -> Option<SystemTime>
pub fn changed(&self) -> Option<SystemTime>
POSIX status-change time; this is not a creation timestamp.