parameters: (self, path)
docstring: Check cache for listing
  
          Returns listing, if found (may me empty list for a directly that exists
          but contains nothing), None if not in cache.
docstring_summary: Check cache for listing
docstring_tokens: Check cache for listing
function: def _ls_from_cache(self, path):
          """Check cache for listing
  
          Returns listing, if found (may me empty list for a directly that exists
          but contains nothing), None if not in cache.
          """
          parent = self._parent(path)
          try:
              return self.dircache[path]
          except KeyError:
              pass
          try:
              files = [f for f in self.dircache[parent] if f["name"] == path]
              if len(files) == 0:
                  # parent dir was listed but did not contain this file
                  raise FileNotFoundError(path)
              return files
          except KeyError:
              pass
function_tokens: def _ls_from_cache ( self , path ) : parent = self . _parent ( path ) try : return self . dircache [ path ] except KeyError : pass try : files = [ f for f in self . dircache [ parent ] if f [ "name" ] == path ] if len ( files ) == 0 : # parent dir was listed but did not contain this file raise FileNotFoundError ( path ) return files except KeyError : pass