Class CountingInputStream

    • Constructor Detail

      • CountingInputStream

        public CountingInputStream(InputStream in)
    • Method Detail

      • count

        protected final void count(long read)
        Increments the counter of already read bytes. Doesn't increment if the EOF has been hit (read == -1)
        Parameters:
        read - the number of bytes read
      • getBytesRead

        public long getBytesRead()
        Returns the current number of bytes read from this stream.
        Returns:
        the number of read bytes