Class GZIPUtils


  • public class GZIPUtils
    extends Object
    • Constructor Detail

      • GZIPUtils

        public GZIPUtils()
    • Method Detail

      • compressBufferToArray

        public static byte[] compressBufferToArray​(ByteBuffer input)
        Return a new byte array with the compressed contents of the input buffer
        Parameters:
        input - byte buffer to compress
        Returns:
        a byte array containing the compressed data, or null if the input was null or there was an unexpected IOException while compressing
      • uncompressBufferToArray

        public static byte[] uncompressBufferToArray​(ByteBuffer contentBuffer)
      • uncompressStreamToArray

        public static byte[] uncompressStreamToArray​(InputStream stream)