filepather-0.3.0: src/System/FilePath/FilePather/FileType.hs
module System.FilePath.FilePather.FileType
(
FileType(..)
, isFile
, isDirectory
, isUnknown
) where
-- | The possible types of a file.
data FileType =
File -- ^ The type is a normal file.
| Directory -- ^ The type is a directory.
| Unknown -- ^ The type is unknown.
deriving (Eq, Ord, Show, Enum)
isFile ::
FileType
-> Bool
isFile =
(==) File
isDirectory ::
FileType
-> Bool
isDirectory =
(==) Directory
isUnknown ::
FileType
-> Bool
isUnknown =
(==) Unknown