Remove PathScanner::run_scan and use PathScanner::run_scan_internal directly
This commit is contained in:
parent
f54092dada
commit
3066bd48da
@ -78,12 +78,10 @@ PathScanner::find_files_matching_regex (vector<string>& result,
|
||||
return;
|
||||
}
|
||||
|
||||
result = run_scan (dirpath,
|
||||
regexp_filter,
|
||||
&compiled_pattern,
|
||||
match_fullpath,
|
||||
return_fullpath,
|
||||
limit, recurse);
|
||||
run_scan_internal (result, dirpath,
|
||||
regexp_filter, &compiled_pattern,
|
||||
match_fullpath, return_fullpath,
|
||||
limit, recurse);
|
||||
|
||||
regfree (&compiled_pattern);
|
||||
}
|
||||
@ -105,19 +103,6 @@ PathScanner::operator() (const string &dirpath, const string ®exp,
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
vector<string>
|
||||
PathScanner::run_scan (const string &dirpath,
|
||||
bool (*filter)(const string &, void *),
|
||||
void *arg,
|
||||
bool match_fullpath, bool return_fullpath,
|
||||
long limit,
|
||||
bool recurse)
|
||||
{
|
||||
vector<string> result;
|
||||
run_scan_internal (result, dirpath, filter, arg, match_fullpath, return_fullpath, limit, recurse);
|
||||
return result;
|
||||
}
|
||||
|
||||
void
|
||||
PathScanner::run_scan_internal (vector<string>& result,
|
||||
|
@ -41,12 +41,12 @@ class LIBPBD_API PathScanner
|
||||
bool return_fullpath = true,
|
||||
long limit = -1,
|
||||
bool recurse = false) {
|
||||
return run_scan (dirpath,
|
||||
filter,
|
||||
arg,
|
||||
match_fullpath,
|
||||
return_fullpath,
|
||||
limit, recurse);
|
||||
std::vector<std::string> result;
|
||||
run_scan_internal (result, dirpath,
|
||||
filter, arg,
|
||||
match_fullpath, return_fullpath,
|
||||
limit, recurse);
|
||||
return result;
|
||||
}
|
||||
|
||||
std::vector<std::string> operator() (const std::string &dirpath,
|
||||
@ -77,14 +77,6 @@ class LIBPBD_API PathScanner
|
||||
long limit,
|
||||
bool recurse = false);
|
||||
|
||||
std::vector<std::string> run_scan (const std::string &dirpath,
|
||||
bool (*filter)(const std::string &, void *),
|
||||
void *arg,
|
||||
bool match_fullpath,
|
||||
bool return_fullpath,
|
||||
long limit,
|
||||
bool recurse = false);
|
||||
|
||||
void run_scan_internal (std::vector<std::string>&,
|
||||
const std::string &dirpath,
|
||||
bool (*filter)(const std::string &, void *),
|
||||
|
Loading…
Reference in New Issue
Block a user