iterglob_infos#

barecat.util.glob_helper.GlobHelper.iterglob_infos(pattern, recursive=False, include_hidden=False, bufsize=None, only_files=False)[source]#

Iterate over file and directory info objects matching a pattern.

The glob syntax is equivalent to Python’s glob.glob().

Parameters:
  • pattern (str) – Glob pattern.

  • recursive (bool) – Whether to glob recursively. If True, the pattern can contain the '/**/' sequence to match any number of directories.

  • include_hidden (bool) – Whether to include hidden files and directories (those starting with a dot).

  • bufsize (Optional[int]) – Buffer size for fetching rows.

  • only_files (bool) – Whether to glob only files and not directories.

Returns:

An iterator over the file and directory info objects.

Return type:

Iterator[barecat.core.types.BarecatEntryInfo]