[][src]Enum termscp::fs::FsEntry

pub enum FsEntry {
    Directory(FsDirectory),
    File(FsFile),
}

FsEntry

FsEntry represents a generic entry in a directory

Variants

Directory(FsDirectory)
File(FsFile)

Implementations

impl FsEntry[src]

pub fn get_abs_path(&self) -> PathBuf[src]

get_abs_path

Get absolute path from FsEntry

pub fn get_name(&self) -> &str[src]

get_name

Get file name from FsEntry

pub fn get_last_change_time(&self) -> SystemTime[src]

get_last_change_time

Get last change time from FsEntry

pub fn get_last_access_time(&self) -> SystemTime[src]

get_last_access_time

Get access time from FsEntry

pub fn get_creation_time(&self) -> SystemTime[src]

get_creation_time

Get creation time from FsEntry

pub fn get_size(&self) -> usize[src]

get_size

Get size from FsEntry. For directories is always 4096

pub fn get_ftype(&self) -> Option<String>[src]

get_ftype

Get file type from FsEntry. For directories is always None

pub fn get_user(&self) -> Option<u32>[src]

get_user

Get uid from FsEntry

pub fn get_group(&self) -> Option<u32>[src]

get_group

Get gid from FsEntry

pub fn get_unix_pex(&self) -> Option<(u8, u8, u8)>[src]

get_unix_pex

Get unix pex from FsEntry

Returns whether the FsEntry is a symlink

pub fn is_dir(&self) -> bool[src]

is_dir

Returns whether a FsEntry is a directory

pub fn is_file(&self) -> bool[src]

is_file

Returns whether a FsEntry is a File

pub fn is_hidden(&self) -> bool[src]

is_hidden

Returns whether FsEntry is hidden

pub fn get_realfile(&self) -> FsEntry[src]

get_realfile

Return the real file pointed by a FsEntry

Trait Implementations

impl Clone for FsEntry[src]

impl Debug for FsEntry[src]

impl Display for FsEntry[src]

pub fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

fmt_ls

Format File Entry as ls does

Auto Trait Implementations

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> Same<T> for T

type Output = T

Should always be Self

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

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,