Class RpcGZIPInputStream

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

    public class RpcGZIPInputStream
    extends com.jcraft.jzlib.InflaterInputStream
    A lightweight wrapper around the JZlib ZIP input stream for processing compressed streams being sent from Perforce servers when the client "client compress" mode is enabled.

    Note that the Perforce version of the GZIP stream dispenses with headers and trailers, but is otherwise fairly standard (which is why this works).

    • Field Summary

      • Fields inherited from class com.jcraft.jzlib.InflaterInputStream

        buf, DEFAULT_BUFSIZE, inflater, myinflater
      • Fields inherited from class java.io.FilterInputStream

        in
    • Constructor Summary

      Constructors 
      Constructor Description
      RpcGZIPInputStream​(java.io.InputStream in)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void close()  
      int read()  
      int read​(byte[] bytes)  
      int read​(byte[] bytes, int offset, int len)  
      • Methods inherited from class com.jcraft.jzlib.InflaterInputStream

        available, fill, getAvailIn, getInflater, getTotalIn, getTotalOut, mark, markSupported, readHeader, reset, skip
      • Methods inherited from class java.io.InputStream

        nullInputStream, readAllBytes, readNBytes, readNBytes, transferTo
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RpcGZIPInputStream

        public RpcGZIPInputStream​(java.io.InputStream in)
                           throws java.io.IOException
        Throws:
        java.io.IOException
    • Method Detail

      • read

        public int read​(byte[] bytes)
                 throws java.io.IOException
        Overrides:
        read in class java.io.FilterInputStream
        Throws:
        java.io.IOException
      • read

        public int read​(byte[] bytes,
                        int offset,
                        int len)
                 throws java.io.IOException
        Overrides:
        read in class com.jcraft.jzlib.InflaterInputStream
        Throws:
        java.io.IOException
      • read

        public int read()
                 throws java.io.IOException
        Overrides:
        read in class com.jcraft.jzlib.InflaterInputStream
        Throws:
        java.io.IOException
      • close

        public void close()
                   throws java.io.IOException
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface java.io.Closeable
        Overrides:
        close in class com.jcraft.jzlib.InflaterInputStream
        Throws:
        java.io.IOException