protected Set<Resource> doFindMatchingFileSystemResources(File rootDir, String subPattern) throws IOException {
        if (LOGGER.isTraceEnabled()) {
            LOGGER.trace("Looking for matching resources in directory tree [{}]", rootDir.getPath());
        }
        Set<File> matchingFiles = retrieveMatchingFiles(rootDir, subPattern);
        Set<Resource> result = new LinkedHashSet<>(matchingFiles.size());
        for (File file : matchingFiles) {
            result.add(new FileSystemResource(file));
        }
        return result;
    }
Find all resources in the file system that match the given location pattern
via the Ant-style PathMatcher.

@param rootDir    the root directory in the file system
@param subPattern the sub pattern to match (below the root directory)
@return a mutable Set of matching Resource instances
@throws IOException in case of I/O errors
see #retrieveMatchingFiles
see org.springframework.util.PathMatcher
analyzer/src/main/java/nl/basjes/parse/useragent/utils/springframework/core/io/support/PathMatchingResourcePatternResolver.java