#include <glob_filter.h>
Data Structures | |
struct | fnmatcher |
function object for fnmatching More... | |
Public Member Functions | |
glob_filter (std::string const &include_patterns, std::string const &exclude_patterns) | |
glob_filter (std::vector< std::string > const &include_patterns, std::vector< std::string > const &exclude_patterns) | |
virtual bool | match (std::string const &str) const |
Returns true if the given string matches. | |
Protected Attributes | |
std::vector< std::string > | include |
include patterns | |
std::vector< std::string > | exclude |
exclude patterns |
glob_filter - filtering of a string based on globbed include/exclude list
This class is an oracle on whether a particular string matches the given list of included and excluded strings.
This class gives glob-based matches on each pattern, as with fnmatch(3)
Definition at line 25 of file glob_filter.h.
glob_filter::glob_filter | ( | std::string const & | include_patterns, | |
std::string const & | exclude_patterns | |||
) | [inline] |
Initialise the filter with the include and exclude list, comma-separated.
Definition at line 31 of file glob_filter.h.
glob_filter::glob_filter | ( | std::vector< std::string > const & | include_patterns, | |
std::vector< std::string > const & | exclude_patterns | |||
) | [inline] |
Initialise the filter with the include and exclude list.
Definition at line 38 of file glob_filter.h.
virtual bool glob_filter::match | ( | std::string const & | str | ) | const [virtual] |
Returns true if the given string matches.
Reimplemented from string_filter.
Reimplemented in path_filter.
Referenced by profile_spec::match().
std::vector<std::string> string_filter::exclude [protected, inherited] |
exclude patterns
Definition at line 52 of file string_filter.h.
std::vector<std::string> string_filter::include [protected, inherited] |
include patterns
Definition at line 50 of file string_filter.h.