Returns a list of files that are not on disk.
439366
def files_ondisk(self, file_objs: models.File) -> set:
        """"""

        return set([ file_obj for file_obj in file_objs if Path(file_obj.full_path).is_file() ])
284003
def _file_list(self, folder):
        ''''''
        rtn = []
        walk = self._walk_report(folder)
        for key,val in walk.items():
            for v in val:
                x=os.path.join(key,v)
                rtn.append(x)

        self.file_count = len(rtn)  #a count of the files we'll have in the final cleaned sosreport, for reporting
        return rtn
782784
def _get_all_files(self, path, *exclude):
        '''
        
        '''
        files = list()
        dirs = list()
        links = list()

        if os.access(path, os.R_OK):
            for obj in os.listdir(path):
                obj = os.path.join(path, obj)
                valid = True
                for ex_obj in exclude:
                    if obj.startswith(str(ex_obj)):
                        valid = False
                        continue
                if not valid or not os.path.exists(obj) or not os.access(obj, os.R_OK):
                    continue
                if salt.utils.path.islink(obj):
                    links.append(obj)
                elif os.path.isdir(obj):
                    dirs.append(obj)
                    f_obj, d_obj, l_obj = self._get_all_files(obj, *exclude)
                    files.extend(f_obj)
                    dirs.extend(d_obj)
                    links.extend(l_obj)
                elif os.path.isfile(obj):
                    files.append(obj)

        return sorted(files), sorted(dirs), sorted(links)
830479
def _get_contents(self):
        """"""
        def files():
            for value in super(GlobBundle, self)._get_contents():
                for path in glob.glob(value):
                    yield path
        return list(files())
223375
def amax_files():
    
    return [os.path.join(dp, f) for dp, dn, filenames in os.walk(CACHE_FOLDER)
            for f in filenames if os.path.splitext(f)[1].lower() == '.am']
964612
def ListFiles(self, ext_attrs=None):
    """"""
    del ext_attrs  # Unused.

    if not self.IsDirectory():
      raise IOError("%s is not a directory" % self.pathspec.CollapsePath())

    for f in self.fd.as_directory():
      try:
        name = _DecodeUTF8WithWarning(f.info.name.name)
        # Drop these useless entries.
        if name in [".", ".."] or name in self.BLACKLIST_FILES:
          continue

        # First we yield a standard response using the default attributes.
        yield self.MakeStatResponse(f, tsk_attribute=None, append_name=name)

        # Now send back additional named attributes for the ADS.
        for attribute in f:
          if attribute.info.type in [
              pytsk3.TSK_FS_ATTR_TYPE_NTFS_DATA, pytsk3.TSK_FS_ATTR_TYPE_DEFAULT
          ]:
            if attribute.info.name:
              yield self.MakeStatResponse(
                  f, append_name=name, tsk_attribute=attribute)
      except AttributeError:
        pass
308541
def collect_non_report_files(args, discovered_files):
    
    excl_paths = exclude_paths(args)
    abs_root = os.path.abspath(args.root)
    non_report_files = []
    for root, dirs, files in os.walk(args.root, followlinks=args.follow_symlinks):
        dirs[:] = filter_dirs(root, dirs, excl_paths)

        for filename in files:
            if not is_source_file(args, filename):
                continue
            abs_filepath = os.path.join(os.path.abspath(root), filename)
            if is_excluded_path(args, abs_filepath):
                continue
            filepath = os.path.relpath(abs_filepath, abs_root)
            if filepath not in discovered_files:
                src_report = {}
                src_report['name'] = posix_path(filepath)
                coverage = []
                with io.open(abs_filepath, mode='rb') as fobj:
                    for _ in fobj:
                        coverage.append(None)
                    fobj.seek(0)
                    src_report['source_digest'] = hashlib.md5(fobj.read()).hexdigest()
                src_report['coverage'] = coverage
                non_report_files.append(src_report)
    return non_report_files
399472
def fetchFiles(self):
        """"""
        print("Fetching files from {}".format(self.baseDir))
        files = glob(path.join(self.baseDir, '*'))
        filesDef = []
        for f in files:
            print("Found SPARQL file {}".format(f))
            relative = f.replace(self.baseDir, '')
            filesDef.append({
                'download_url': relative,
                'name': relative
            })
        return filesDef
613204
def _all_filenames(self):
        """"""
        try:
            return [os.path.join(self.cache_dir, filename) for filename in
                    os.listdir(self.cache_dir)]
        except (FileNotFoundError, OSError):
            return []
1317818
def get_files_from_storage(paths):
        """"""
        for path in paths:
            f = default_storage.open(path)
            f.name = os.path.basename(path)
            try:
                yield f
            except ClientError:
                logger.exception("File not found: %s", path)
1152004
def get_image_files(c:PathOrStr, check_ext:bool=True, recurse=False)->FilePathList:
    ""
    return get_files(c, extensions=(image_extensions if check_ext else None), recurse=recurse)
29253
private static List<Path> file_listing_(Path dir) throws IOException {
        try (Stream<Path> files = Files.list(dir)) {
            return files.collect(Collectors.toList());
        }
    }
412752
def get_files(files, extnames=['.root']):
    """"""

    files_out = []
    for f in files:

        mime = mimetypes.guess_type(f)
        if os.path.splitext(f)[1] in extnames:
            files_out += [f]
        elif mime[0] == 'text/plain':
            files_out += list(np.loadtxt(f, unpack=True, dtype='str'))
        else:
            raise Exception('Unrecognized input type.')

    return files_out
381063
def files(self):
        """"""
        if self._files is None:
            self._files = SeriesZipTifHolo._index_files(self.path)
        return self._files
1316798
def files(self, *args, **kwargs):
        

        return [p for p in self.listdir(*args, **kwargs) if p.isfile()]
540299
def get_recent_files(self):
        """"""
        try:
            recent_files = self.CONF[WORKSPACE].get('main', 'recent_files',
                                                    default=[])
        except EnvironmentError:
            return []

        for recent_file in recent_files[:]:
            if not os.path.isfile(recent_file):
                recent_files.remove(recent_file)
        return list(OrderedDict.fromkeys(recent_files))
1009558
def get_ignored_tracks(self, localdir):
        
        ignore_file = "%s/.ignore" % localdir
        list = []
        if os.path.exists(ignore_file):
            f = open(ignore_file)
            ignored = f.readlines()
            f.close()

            for i in ignored:
                list.append("%s/%s" % (localdir, i.rstrip()))

        return list