pub struct Metadata {
pub permissions: Permissions,
pub len: u64,
pub modified: Option<Duration>,
pub accessed: Option<Duration>,
pub created: Option<Duration>,
}
Expand description
Directory list entry metadata.
This type is equivalent to Metadata
in the standard library.
Fields§
§permissions: Permissions
§len: u64
§modified: Option<Duration>
Modified time (since unix epoch, or other point)
accessed: Option<Duration>
Accessed time (since unix epoch, or other point)
created: Option<Duration>
Created time (since unix epoch, or other point)
Implementations§
source§impl Metadata
impl Metadata
pub fn empty_file(permissions: Permissions, created: Option<Duration>) -> Self
pub fn empty_dir(permissions: Permissions, created: Option<Duration>) -> Self
Trait Implementations§
source§impl<'de> Deserialize<'de> for Metadata
impl<'de> Deserialize<'de> for Metadata
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Ord for Metadata
impl Ord for Metadata
source§impl PartialEq for Metadata
impl PartialEq for Metadata
source§impl PartialOrd for Metadata
impl PartialOrd for Metadata
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Eq for Metadata
impl StructuralEq for Metadata
impl StructuralPartialEq for Metadata
Auto Trait Implementations§
impl RefUnwindSafe for Metadata
impl Send for Metadata
impl Sync for Metadata
impl Unpin for Metadata
impl UnwindSafe for Metadata
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