Interface FilesCache

    • Method Detail

      • putFile

        void putFile​(FileObject file)
        Adds a FileObject to the cache.
        Parameters:
        file - the file
      • putFileIfAbsent

        boolean putFileIfAbsent​(FileObject file)
        Adds a FileObject to the cache if it isn't already present.
        Parameters:
        file - the file
        Returns:
        true if the file was stored, false otherwise.
      • getFile

        FileObject getFile​(FileSystem filesystem,
                           FileName name)
        Retrieves a FileObject from the cache by name.
        Parameters:
        filesystem - The FileSystem.
        name - the name
        Returns:
        the file object or null if file is not cached
      • clear

        void clear​(FileSystem fileSystem)
        Purges the entries corresponding to the FileSystem.
        Parameters:
        fileSystem - The FileSystem.
      • close

        void close()
        Purges the whole cache.
      • removeFile

        void removeFile​(FileSystem filesystem,
                        FileName name)
        Removes a file from cache.
        Parameters:
        filesystem - filesystem
        name - filename