Struct rcore_fs::vfs::Metadata[][src]

pub struct Metadata {
    pub dev: usize,
    pub inode: usize,
    pub size: usize,
    pub blk_size: usize,
    pub blocks: usize,
    pub atime: Timespec,
    pub mtime: Timespec,
    pub ctime: Timespec,
    pub type_: FileType,
    pub mode: u16,
    pub nlinks: usize,
    pub uid: usize,
    pub gid: usize,
    pub rdev: usize,
}

Metadata of INode

Ref: [http://pubs.opengroup.org/onlinepubs/009604499/basedefs/sys/stat.h.html]

Fields

dev: usize

Device ID

inode: usize

Inode number

size: usize

Size in bytes

SFS Note: for normal file size is the actuate file size for directory this is count of dirent.

blk_size: usize

A file system-specific preferred I/O block size for this object. In some file system types, this may vary from file to file.

blocks: usize

Size in blocks

atime: Timespec

Time of last access

mtime: Timespec

Time of last modification

ctime: Timespec

Time of last change

type_: FileType

Type of file

mode: u16

Permission

nlinks: usize

Number of hard links

SFS Note: different from linux, “.” and “..” count in nlinks this is same as original ucore.

uid: usize

User ID

gid: usize

Group ID

rdev: usize

Raw device id e.g. /dev/null: makedev(0x1, 0x3)

Trait Implementations

impl Clone for Metadata[src]

impl Debug for Metadata[src]

impl Eq for Metadata[src]

impl From<Metadata> for Metadata[src]

impl PartialEq<Metadata> for Metadata[src]

impl StructuralEq for Metadata[src]

impl StructuralPartialEq for Metadata[src]

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

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.