Struct std::old_io::FileStatUnstable
[-] [+]
[src]
pub struct FileStat { pub size: u64, pub kind: FileType, pub perm: FilePermission, pub created: u64, pub modified: u64, pub accessed: u64, pub unstable: UnstableFileStat, }
A structure used to describe metadata information about a file. This
structure is created through the stat
method on a Path
.
Examples
fn main() { use std::old_io::fs::PathExtensions; let info = match Path::new("foo.txt").stat() { Ok(stat) => stat, Err(e) => panic!("couldn't read foo.txt: {}", e), }; println!("byte size: {}", info.size); }use std::old_io::fs::PathExtensions; let info = match Path::new("foo.txt").stat() { Ok(stat) => stat, Err(e) => panic!("couldn't read foo.txt: {}", e), }; println!("byte size: {}", info.size);