Determines whether or not resource is filtered.
        Resources may be filtered if the tags do not match
        or the user has specified explict paths to include
        or exclude via command line options
182489
def filtered(self):
        """"""
        if not is_tagged(self.tags, self.opt.tags):
            LOG.info("Skipping %s as it does not have requested tags",
                     self.path)
            return False

        if not specific_path_check(self.path, self.opt):
            LOG.info("Skipping %s as it does not match specified paths",
                     self.path)
            return False

        return True
20819
def may_contain_matches(self, path):
        
        path = self._prepare_path(path)
        return self.int_regex.search(path) is not None
743745
def is_excluded(self, path, exclude=None):
        
        for pattern in (exclude or self.exclude_pattern):
            if path.match(pattern):
                return True
        else:
            return False
424835
public boolean isAllowed(String path) {
    for (String filter : STARTS_WITH_FILTER) {
      if (path.startsWith(filter)) {
        return false;
      }
    }
    for (String filter : CONTAINS_FILTER) {
      if (path.contains(filter)) {
        return false;
      }
    }
    return true;
  }
1357164
def row_is_filtered(self, row_subs, filters):
        ''''''
        for filtername in filters:
            filtervalue = filters[filtername]
            if filtername in row_subs:
                row_subs_value = row_subs[filtername]
                if str(row_subs_value) != str(filtervalue):
                    return True
            else:
                print("fw: Unknown filter keyword (%s)" % (filtername,))
        return False
15516
def filter_exclusions file_paths
      file_paths.reject do |path|
        exclude_file_patterns.any? { |pattern| File.fnmatch("#{pattern}", path) || File.fnmatch("**/#{pattern}", path) }
      end
    end
56525
def is_excluded(root, excludes):
    
    root = os.path.normpath(root)
    for exclude in excludes:
        if root == exclude:
            return True
    return False
180658
def excluded?(filename)
      exclude.each do |f|
        f += '**/*' if f.end_with? '/'
        return true if File.fnmatch(f, filename, File::FNM_EXTGLOB | File::FNM_PATHNAME)
      end
      false
    end
1177434
private boolean shouldExcludeSourceFile(CompilationUnitTree tree) {
    Pattern excludedPattern = errorProneOptions.getExcludedPattern();
    return excludedPattern != null
        && excludedPattern.matcher(ASTHelpers.getFileName(tree)).matches();
  }
351910
def _check_filter_includes(self, includes: list, resource: str = "metadata"):
        
        # check resource parameter
        if resource == "metadata":
            ref_subresources = _SUBRESOURCES_MD
        elif resource == "keyword":
            ref_subresources = _SUBRESOURCES_KW
        else:
            raise ValueError("Must be one of: metadata | keyword.")

        # sub resources manager
        if isinstance(includes, str) and includes.lower() == "all":
            includes = ",".join(ref_subresources)
        elif isinstance(includes, list):
            if len(includes) > 0:
                includes = ",".join(includes)
            else:
                includes = ""
        else:
            raise TypeError("'includes' expect a list or a str='all'")
        return includes
1035189
def ignore_path(path, ignore_list=None, whitelist=None):
    
    if ignore_list is None:
        return True

    should_ignore = matches_glob_list(path, ignore_list)
    if whitelist is None:
        return should_ignore

    return should_ignore and not matches_glob_list(path, whitelist)
256276
def is_uri_to_be_filtered(uri, filter_list):
    """"""
    match = False
    if filter_list:
        for uri_filter in filter_list:
            if re.search(uri_filter, uri, flags=re.IGNORECASE):
                match = True
        return match
721572
protected boolean containsResource(CmsResource res) {

        return m_deletedFolderList.contains(res) || m_folderList.contains(res) || m_fileList.contains(res);
    }
877022
def is_filtered?(severity, message)
      if filters = MESSAGE_FILTERS[severity]
        filters.each do |filter|
          return true if filter =~ message
        end
      end
      return false
    end
609734
def _is_process_filtered(self, process, key=None):
        """"""
        if key is None:
            key = self.filter_key
        try:
            # If the item process[key] is a list, convert it to a string
            # in order to match it with the current regular expression
            if isinstance(process[key], list):
                value = ' '.join(process[key])
            else:
                value = process[key]
        except KeyError:
            # If the key did not exist
            return False
        try:
            return self._filter_re.match(value) is None
        except (AttributeError, TypeError):
            # AttributeError
            # Filter processes crashs with a bad regular expression pattern (issue #665)
            # TypeError
            # Filter processes crashs if value is None (issue #1105)
            return False
611153
def resource_index
      if self.class.included_modules.include? APPI::FiltersResources
        apply_filter_params resource_class.all
      else
        resource_class.all
      end
    end
1147785
def _filtered(self, text):
        '''
        
        '''
        filtered = None
        # Text is converted to lower case first, partially for historical
        # purposes, but also because it simplifies writing filter rules
        # (e.g., don't have to worry about case sensitivity).
        text = text.lower()

        for include in self.includes:
            if include.search(text):
                filtered = False
                break

        # If exclusive include filters have been specified and did
        # not match the text, then the text should be filtered out.
        if self.includes and filtered == None:
            return True

        for exclude in self.excludes:
            if exclude.search(text):
                filtered = True
                break

        # If no explicit exclude filters were matched, then the
        # text should *not* be filtered.
        if filtered == None:
            filtered = False

        return filtered