org.apache.jmeter.protocol.http.sampler.hc

## Class LaxGZIPInputStream

- java.lang.Object
- - java.io.InputStream
  - - java.io.FilterInputStream
    - - java.util.zip.InflaterInputStream
      - - java.util.zip.GZIPInputStream
        - - org.apache.jmeter.protocol.http.sampler.hc.LaxGZIPInputStream

- All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable

      public class LaxGZIPInputStream
      extends java.util.zip.GZIPInputStream

  `GZIPInputStream` subclass that has a flag to accept "edgy streams" that signal end of stream with `EOFException` which seems to be rather frequent
  Since:
    5.0
  See Also:
    Bugzilla 61058

- - ### Field Summary

    - ### Fields inherited from class java.util.zip.GZIPInputStream

      `crc, eos, GZIP_MAGIC`

    - ### Fields inherited from class java.util.zip.InflaterInputStream

      `buf, inf, len`

    - ### Fields inherited from class java.io.FilterInputStream

      `in`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `LaxGZIPInputStream(java.io.InputStream wrapped, boolean relax)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `read()`
    `int` | `read(byte[] b)`
    `int` | `read(byte[] b, int off, int len)`

    - ### Methods inherited from class java.util.zip.GZIPInputStream

      `close`

    - ### Methods inherited from class java.util.zip.InflaterInputStream

      `available, fill, mark, markSupported, reset, skip`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### LaxGZIPInputStream

          public LaxGZIPInputStream(java.io.InputStream wrapped,
                                    boolean relax)
                             throws java.io.IOException

      Parameters:
        `wrapped` - the InputStream that should be wrapped
        `relax` - flag to enable relaxed mode
      Throws:
        `java.io.IOException` - when super class throws an IOException

  - ### Method Detail

    - #### read

          public int read(byte[] b,
                          int off,
                          int len)
                   throws java.io.IOException

      Overrides:
        `read` in class `java.util.zip.GZIPInputStream`
      Throws:
        `java.io.IOException`

    - #### read

          public int read()
                   throws java.io.IOException

      Overrides:
        `read` in class `java.util.zip.InflaterInputStream`
      Throws:
        `java.io.IOException`

    - #### read

          public int read(byte[] b)
                   throws java.io.IOException

      Overrides:
        `read` in class `java.io.FilterInputStream`
      Throws:
        `java.io.IOException`

Copyright © 1998-2019 Apache Software Foundation. All Rights Reserved.