Class ZipFileFileSystem

java.lang.Object
hec.map.tms.datasource.filesystem.zipfile.ZipFileFileSystem
All Implemented Interfaces:
FileSystem

public class ZipFileFileSystem extends Object implements FileSystem
Represents a file system for a Zip File. Files that are requested are unzipped and copied to a temp directory. The same hierarchy in the zip file is recreated in the temp directory.
  • Constructor Details

    • ZipFileFileSystem

      public ZipFileFileSystem(File f)
  • Method Details

    • getFileChannel

      public FileChannel getFileChannel(String path)
      Description copied from interface: FileSystem
      Returns a FileChannel for the given path specified. If the path is relative, it will begin from the root of the File System. Null is returned if the file path does not exist.
      Specified by:
      getFileChannel in interface FileSystem
      Returns:
    • exists

      public boolean exists(String path)
      Description copied from interface: FileSystem
      Returns true if the file exists and false if it does not.
      Specified by:
      exists in interface FileSystem
      Returns:
    • close

      public boolean close() throws IOException
      Description copied from interface: FileSystem
      Closes the file system
      Specified by:
      close in interface FileSystem
      Returns:
      Throws:
      IOException