Class Pack200CompressorInputStream

java.lang.Object
java.io.InputStream
org.apache.commons.compress.compressors.CompressorInputStream
org.apache.commons.compress.compressors.pack200.Pack200CompressorInputStream
All Implemented Interfaces:
Closeable, AutoCloseable

public class Pack200CompressorInputStream extends CompressorInputStream
An input stream that decompresses from the Pack200 format to be read as any other stream.

The getCount and getBytesRead methods always return 0.

Since:
1.3
  • Constructor Details

    • Pack200CompressorInputStream

      public Pack200CompressorInputStream(File file) throws IOException
      Decompresses the given file, caching the decompressed data in memory.
      Parameters:
      file - the file to decompress
      Throws:
      IOException - if reading fails
    • Pack200CompressorInputStream

      public Pack200CompressorInputStream(File file, Map<String,String> properties) throws IOException
      Decompresses the given file, caching the decompressed data in memory and using the given properties.
      Parameters:
      file - the file to decompress
      properties - Pack200 properties to use
      Throws:
      IOException - if reading fails
    • Pack200CompressorInputStream

      public Pack200CompressorInputStream(File file, Pack200Strategy mode) throws IOException
      Decompresses the given file using the given strategy to cache the results.
      Parameters:
      file - the file to decompress
      mode - the strategy to use
      Throws:
      IOException - if reading fails
    • Pack200CompressorInputStream

      public Pack200CompressorInputStream(File file, Pack200Strategy mode, Map<String,String> properties) throws IOException
      Decompresses the given file using the given strategy to cache the results and the given properties.
      Parameters:
      file - the file to decompress
      mode - the strategy to use
      properties - Pack200 properties to use
      Throws:
      IOException - if reading fails
    • Pack200CompressorInputStream

      public Pack200CompressorInputStream(InputStream inputStream) throws IOException
      Decompresses the given stream, caching the decompressed data in memory.

      When reading from a file the File-arg constructor may provide better performance.

      Parameters:
      inputStream - the InputStream from which this object should be created
      Throws:
      IOException - if reading fails
    • Pack200CompressorInputStream

      public Pack200CompressorInputStream(InputStream inputStream, Map<String,String> properties) throws IOException
      Decompresses the given stream, caching the decompressed data in memory and using the given properties.

      When reading from a file the File-arg constructor may provide better performance.

      Parameters:
      inputStream - the InputStream from which this object should be created
      properties - Pack200 properties to use
      Throws:
      IOException - if reading fails
    • Pack200CompressorInputStream

      public Pack200CompressorInputStream(InputStream inputStream, Pack200Strategy mode) throws IOException
      Decompresses the given stream using the given strategy to cache the results.

      When reading from a file the File-arg constructor may provide better performance.

      Parameters:
      inputStream - the InputStream from which this object should be created
      mode - the strategy to use
      Throws:
      IOException - if reading fails
    • Pack200CompressorInputStream

      public Pack200CompressorInputStream(InputStream inputStream, Pack200Strategy mode, Map<String,String> properties) throws IOException
      Decompresses the given stream using the given strategy to cache the results and the given properties.

      When reading from a file the File-arg constructor may provide better performance.

      Parameters:
      inputStream - the InputStream from which this object should be created
      mode - the strategy to use
      properties - Pack200 properties to use
      Throws:
      IOException - if reading fails
  • Method Details