#[non_exhaustive]pub enum FileType {
Fifo,
CharDevice,
Directory,
BlockDevice,
Regular,
Symlink,
Socket,
Other(u16),
}Expand description
The S_IFMT file type decoded from di_mode.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Fifo
FIFO / named pipe (S_IFIFO).
CharDevice
Character device (S_IFCHR).
Directory
Directory (S_IFDIR).
BlockDevice
Block device (S_IFBLK).
Regular
Regular file (S_IFREG).
Symlink
Symbolic link (S_IFLNK).
Socket
Unix-domain socket (S_IFSOCK).
Other(u16)
A type field not matching any known S_IFMT value — carried verbatim.
Implementations§
Trait Implementations§
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 UnsafeUnpin 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