Struct rsfs::mem::unix::Metadata
[−]
[src]
pub struct Metadata(_);
Metadata information about a file.
This structure, which implements rsfs::Metadata
, is returned from the metadata
or
symlink_metadata
methods and represents known metadata information about a file at the
instant in time this structure is instantiated.
Examples
let fs = FS::new(); fs.create_file("f")?; println!("{:?}", fs.metadata("f")?);
Trait Implementations
impl Clone for Metadata
[src]
fn clone(&self) -> Metadata
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl Debug for Metadata
[src]
impl Metadata for Metadata
[src]
type Permissions = Permissions
The Permissions
type in the same module implementing this trait.
type FileType = FileType
The FileType
type in the same module implementing this trait.
fn file_type(&self) -> Self::FileType
Returns the file type for this metadata. Read more
fn is_dir(&self) -> bool
Returns whether this metadata is for a directory. Read more
fn is_file(&self) -> bool
Returns whether this metadata is for a file. Read more
fn len(&self) -> u64
Returns the size, in bytes, of the file this metadata is for. Read more
fn permissions(&self) -> Self::Permissions
Returns the permissions of the file this metadata is for. Read more
fn modified(&self) -> Result<SystemTime>
Returns the last modification time listed in this metadata. Read more
fn accessed(&self) -> Result<SystemTime>
Returns the last access time listed in this metadata. Read more
fn created(&self) -> Result<SystemTime>
Returns the creation time listed in this metadata. Read more
fn is_empty(&self) -> bool
Returns whether the file is empty. This defaults to checking len() == 0
. Read more