pub enum FileType {
BlockDevice,
CharacterDevice,
Directory,
Fifo,
Regular,
Socket,
Symlink,
}
Expand description
File type.
Variants§
BlockDevice
Block device.
CharacterDevice
Character device.
Directory
Directory.
Fifo
First-in first-out (FIFO) special file.
Regular
Regular file.
Socket
Socket file.
Symlink
Symbolic link.
Implementations§
Source§impl FileType
impl FileType
Sourcepub fn is_block_dev(self) -> bool
pub fn is_block_dev(self) -> bool
Returns true if the file is a block device.
Sourcepub fn is_char_dev(self) -> bool
pub fn is_char_dev(self) -> bool
Returns true if the file is a character device.
Sourcepub fn is_fifo(self) -> bool
pub fn is_fifo(self) -> bool
Returns true if the file is a first-in first-out (FIFO) special file.
Sourcepub fn is_regular_file(self) -> bool
pub fn is_regular_file(self) -> bool
Returns true if the file is a regular file.
Sourcepub fn is_symlink(self) -> bool
pub fn is_symlink(self) -> bool
Returns true if the file is a symlink.
Trait Implementations§
Source§impl Ord for FileType
impl Ord for FileType
Source§impl PartialOrd for FileType
impl PartialOrd for FileType
impl Copy for FileType
impl Eq for FileType
impl StructuralPartialEq for FileType
Auto Trait Implementations§
impl Freeze for FileType
impl RefUnwindSafe for FileType
impl Send for FileType
impl Sync for FileType
impl Unpin for FileType
impl UnwindSafe for FileType
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