Class NoFetchingInput

    • Field Summary

      • Fields inherited from class com.esotericsoftware.kryo.io.Input

        buffer, capacity, chars, inputStream, limit, position, total
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean canReadInt()  
      boolean canReadLong()  
      boolean eof()  
      int read()  
      int read​(byte[] bytes, int offset, int count)  
      void readBytes​(byte[] bytes, int offset, int count)  
      protected int require​(int required)
      Require makes sure that at least required number of bytes are kept in the buffer.
      void skip​(int count)  
      • Methods inherited from class com.esotericsoftware.kryo.io.Input

        available, close, fill, getBuffer, getInputStream, limit, position, read, readBoolean, readByte, readBytes, readBytes, readByteUnsigned, readChar, readChars, readDouble, readDouble, readDoubles, readFloat, readFloat, readFloats, readInt, readInt, readInts, readInts, readLong, readLong, readLongs, readLongs, readShort, readShorts, readShortUnsigned, readString, readStringBuilder, readVarInt, readVarLong, rewind, setBuffer, setBuffer, setInputStream, setLimit, setPosition, setTotal, skip, total
    • Constructor Detail

      • NoFetchingInput

        public NoFetchingInput​(InputStream inputStream)
    • Method Detail

      • eof

        public boolean eof()
        Overrides:
        eof in class com.esotericsoftware.kryo.io.Input
      • read

        public int read()
                 throws com.esotericsoftware.kryo.KryoException
        Overrides:
        read in class com.esotericsoftware.kryo.io.Input
        Throws:
        com.esotericsoftware.kryo.KryoException
      • canReadInt

        public boolean canReadInt()
                           throws com.esotericsoftware.kryo.KryoException
        Overrides:
        canReadInt in class com.esotericsoftware.kryo.io.Input
        Throws:
        com.esotericsoftware.kryo.KryoException
      • canReadLong

        public boolean canReadLong()
                            throws com.esotericsoftware.kryo.KryoException
        Overrides:
        canReadLong in class com.esotericsoftware.kryo.io.Input
        Throws:
        com.esotericsoftware.kryo.KryoException
      • require

        protected int require​(int required)
                       throws com.esotericsoftware.kryo.KryoException
        Require makes sure that at least required number of bytes are kept in the buffer. If not, then it will load exactly the difference between required and currently available number of bytes. Thus, it will only load the data which is required and never prefetch data.
        Overrides:
        require in class com.esotericsoftware.kryo.io.Input
        Parameters:
        required - the number of bytes being available in the buffer
        Returns:
        the number of bytes remaining, which is equal to required
        Throws:
        com.esotericsoftware.kryo.KryoException
      • read

        public int read​(byte[] bytes,
                        int offset,
                        int count)
                 throws com.esotericsoftware.kryo.KryoException
        Overrides:
        read in class com.esotericsoftware.kryo.io.Input
        Throws:
        com.esotericsoftware.kryo.KryoException
      • skip

        public void skip​(int count)
                  throws com.esotericsoftware.kryo.KryoException
        Overrides:
        skip in class com.esotericsoftware.kryo.io.Input
        Throws:
        com.esotericsoftware.kryo.KryoException
      • readBytes

        public void readBytes​(byte[] bytes,
                              int offset,
                              int count)
                       throws com.esotericsoftware.kryo.KryoException
        Overrides:
        readBytes in class com.esotericsoftware.kryo.io.Input
        Throws:
        com.esotericsoftware.kryo.KryoException