Package org.apache.commons.compress.utils

# Interface InputStreamStatistics

All Known Implementing Classes:
  `AbstractLZ77CompressorInputStream`, `BlockLZ4CompressorInputStream`, `BrotliCompressorInputStream`, `BZip2CompressorInputStream`, `Deflate64CompressorInputStream`, `DeflateCompressorInputStream`, `FramedLZ4CompressorInputStream`, `FramedSnappyCompressorInputStream`, `GzipCompressorInputStream`, `JarArchiveInputStream`, `LZMACompressorInputStream`, `LZWInputStream`, `SnappyCompressorInputStream`, `XZCompressorInputStream`, `ZCompressorInputStream`, `ZipArchiveInputStream`, `ZstdCompressorInputStream`

public interface InputStreamStatistics
This interface provides statistics on the current decompression stream. The stream consumer can use that statistics to handle abnormal compression ratios, i.e. to prevent ZIP bombs.

Since:
  1.17

- ## Method Summary

  Modifier and Type
  Method
  Description
  `long`
  `getCompressedCount()`
  Gets the amount of raw or compressed bytes read by the stream.
  `long`
  `getUncompressedCount()`
  Gets the amount of decompressed bytes returned by the stream.

- ## Method Details

  - ### getCompressedCount

    long getCompressedCount()
    Gets the amount of raw or compressed bytes read by the stream.
    Returns:
      the amount of raw or compressed bytes read by the stream.

  - ### getUncompressedCount

    long getUncompressedCount()
    Gets the amount of decompressed bytes returned by the stream.
    Returns:
      the amount of decompressed bytes returned by the stream.