@Override
    protected boolean accept(Path p, @CheckForNull Boolean isDir) {
      if (!isValidName(p.getName())) {
        return false;
      }

      try {
        return isDirectory(fs, isDir, p);
      } catch (IOException e) {
        LOG.warn("An error occurred while verifying if [{}] is a valid directory."
          + " Returning 'not valid' and continuing.", p, e);
        return false;
      }
    }
Create a filter on the givem filesystem with the specified blacklist
@param fs                     filesystem to filter
@param directoryNameBlackList list of the names of the directories to filter. If
                              <tt>null</tt>, all directories are returned
hbase-server/src/main/java/org/apache/hadoop/hbase/util/FSUtils.java