Class Decoder

java.lang.Object
com.aayushatharva.brotli4j.decoder.Decoder
Direct Known Subclasses:
BrotliDecoderChannel

public class Decoder extends Object
Base class for InputStream / Channel implementations.
  • Constructor Details

    • Decoder

      public Decoder(ReadableByteChannel source, int inputBufferSize) throws IOException
      Creates a Decoder wrapper.
      Parameters:
      source - underlying source
      inputBufferSize - read buffer size
      Throws:
      IOException - If any failure during initialization
  • Method Details

    • decompress

      public static DirectDecompress decompress(byte[] data) throws IOException
      Decodes the given data buffer.
      Parameters:
      data - byte array of data to be decoded
      Returns:
      DirectDecompress instance
      Throws:
      IOException - If an error occurs during decoding
    • enableEagerOutput

      public void enableEagerOutput()