Safe Haskell | None |
---|---|
Language | Haskell2010 |
Text.RE.Tools.Find
Contents
- data FindMethods s = FindMethods {
- doesDirectoryExistDM :: s -> IO Bool
- listDirectoryDM :: s -> IO [s]
- combineDM :: s -> s -> s
- findMatches_ :: IsRegex re s => FindMethods s -> re -> s -> IO [s]
- findMatches_' :: IsRegex re s => FindMethods s -> ([s] -> [s]) -> (Match s -> Bool) -> re -> s -> IO [s]
- module Text.RE
Documentation
data FindMethods s Source #
as we don't want the directory
and FilePath dependencies
we will abstract the three calls we need into this record type
Constructors
FindMethods | |
Fields
|
findMatches_ :: IsRegex re s => FindMethods s -> re -> s -> IO [s] Source #
recursively list all files whose filename matches given RE,
sorting the list into ascending order; if the argument path has a
trailing /
then it will be removed
Arguments
:: IsRegex re s | |
=> FindMethods s | the directory and filepath methods |
-> ([s] -> [s]) | result post-processing function |
-> (Match s -> Bool) | filtering function |
-> re | re to be matched against the leaf filename |
-> s | root directory of the search |
-> IO [s] |
recursively list all files whose filename matches given RE, using the given function to determine which matches to accept
Text.RE
module Text.RE