Class ChecksummedDataInput

    • Field Detail

      • bufferOffset

        protected long bufferOffset
    • Method Detail

      • isEOF

        public boolean isEOF()
      • getSeekPosition

        public InputPosition getSeekPosition()
        Return a seekable representation of the current position. For compressed files this is chunk position in file and offset within chunk.
      • resetCrc

        public void resetCrc()
      • limit

        public void limit​(long newLimit)
      • getPosition

        protected long getPosition()
        Returns the exact position in the uncompressed view of the file.
      • getSourcePosition

        protected long getSourcePosition()
        Returns the position in the source file, which is different for getPosition() for compressed/encrypted files and may be imprecise.
      • resetLimit

        public void resetLimit()
      • checkLimit

        public void checkLimit​(int length)
                        throws java.io.IOException
        Throws:
        java.io.IOException
      • bytesPastLimit

        public long bytesPastLimit()
      • checkCrc

        public boolean checkCrc()
                         throws java.io.IOException
        Throws:
        java.io.IOException
      • readFully

        public void readFully​(byte[] b)
                       throws java.io.IOException
        Specified by:
        readFully in interface java.io.DataInput
        Overrides:
        readFully in class RebufferingInputStream
        Throws:
        java.io.IOException
      • read

        public int read​(byte[] b,
                        int off,
                        int len)
                 throws java.io.IOException
        Overrides:
        read in class RebufferingInputStream
        Throws:
        java.io.IOException
      • reBuffer

        protected void reBuffer()
        Description copied from class: RebufferingInputStream
        Implementations must implement this method to refill the buffer. They can expect the buffer to be empty when this method is invoked.
        Specified by:
        reBuffer in class RebufferingInputStream
      • readBuffer

        protected void readBuffer()
      • tryUncacheRead

        public void tryUncacheRead()
      • close

        public void close()
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface java.io.Closeable
        Overrides:
        close in class java.io.InputStream
      • getPath

        protected java.lang.String getPath()