class_docstr: The :class:`PathSpec` class is a wrapper around a list of compiled
  :class:`.Pattern` instances.
class_docstr_tok: ["The",":","class",":","`","PathSpec","`","class","is","a","wrapper","around","a","list","of","compiled",":","class",":","`",".Pattern","`","instances","."]
docstr: Matches the files to this path-spec.
  
  *files* (:class:`~collections.abc.Iterable` of :class:`str` or
  :class:`os.PathLike`) contains the file paths to be matched against
  :attr:`self.patterns <PathSpec.patterns>`.
  
  *separators* (:class:`~collections.abc.Collection` of :class:`str`; or
  :data:`None`) optionally contains the path separators to normalize. See
  :func:`~pathspec.util.normalize_file` for more information.
  
  *negate* (:class:`bool` or :data:`None`) is whether to negate the match
  results of the patterns. If :data:`True`, a pattern matching a file will
  exclude the file rather than include it. Default is :data:`None` for
  :data:`False`.
  
  Returns the matched files (:class:`~collections.abc.Iterator` of
  :class:`str` or :class:`os.PathLike`).
docstr_tok: ["Matches","the","files","to","this","path-spec",".","*","files","*","(",":","class",":","`","~collections.abc.Iterable","`","of",":","class",":","`","str","`","or",":","class",":","`","os.PathLike","`",")","contains","the","file","paths","to","be","matched","against",":","attr",":","`","self.patterns","<","PathSpec.patterns",">","`",".","*","separators","*","(",":","class",":","`","~collections.abc.Collection","`","of",":","class",":","`","str","`",";","or",":","data",":","`","None","`",")","optionally","contains","the","path","separators","to","normalize",".","See",":","func",":","`","~pathspec.util.normalize_file","`","for","more","information",".","*","negate","*","(",":","class",":","`","bool","`","or",":","data",":","`","None","`",")","is","whether","to","negate","the","match","results","of","the","patterns",".","If",":","data",":","`","True","`",",","a","pattern","matching","a","file","will","exclude","the","file","rather","than","include","it",".","Default","is",":","data",":","`","None","`","for",":","data",":","`","False","`",".","Returns","the","matched","files","(",":","class",":","`","~collections.abc.Iterator","`","of",":","class",":","`","str","`","or",":","class",":","`","os.PathLike","`",")","."]
code: def match_files(
      self,
      files: Iterable[StrPath],
      separators: Optional[Collection[str]] = None,
      *,
      negate: Optional[bool] = None,
  ) -> Iterator[StrPath]:
      """
      Matches the files to this path-spec.
  
      *files* (:class:`~collections.abc.Iterable` of :class:`str` or
      :class:`os.PathLike`) contains the file paths to be matched against
      :attr:`self.patterns <PathSpec.patterns>`.
  
      *separators* (:class:`~collections.abc.Collection` of :class:`str`; or
      :data:`None`) optionally contains the path separators to normalize. See
      :func:`~pathspec.util.normalize_file` for more information.
  
      *negate* (:class:`bool` or :data:`None`) is whether to negate the match
      results of the patterns. If :data:`True`, a pattern matching a file will
      exclude the file rather than include it. Default is :data:`None` for
      :data:`False`.
  
      Returns the matched files (:class:`~collections.abc.Iterator` of
      :class:`str` or :class:`os.PathLike`).
      """
      if not _is_iterable(files):
          raise TypeError(f"files:{files!r} is not an iterable.")
  
      use_patterns = _filter_check_patterns(self.patterns)
      for orig_file in files:
          norm_file = normalize_file(orig_file, separators)
          include, _index = self._match_file(use_patterns, norm_file)
  
          if negate:
              include = not include
  
          if include:
              yield orig_file
  
imports: from collections.abc import Collection
  from itertools import zip_longest
  from typing import AnyStr, Callable, Collection, Iterable, Iterator, Optional, Type, TypeVar, Union
  from .None import util
  from .pattern import Pattern
  from .util import CheckResult, StrPath, TStrPath, TreeEntry, _filter_check_patterns, _is_iterable, normalize_file
label_desc: Use image node_id 12 for calling the PathSpec obj's underlying member method code with example usage: obj.match_files(files, separators) without return types