Interface ByteArrayDataInput

  • All Superinterfaces:
    java.io.DataInput

    @GwtIncompatible
    public interface ByteArrayDataInput
    extends java.io.DataInput
    An extension of DataInput for reading from in-memory byte arrays; its methods offer identical functionality but do not throw IOException.

    Warning: The caller is responsible for not attempting to read past the end of the array. If any method encounters the end of the array prematurely, it throws IllegalStateException to signify programmer error. This behavior is a technical violation of the supertype's contract, which specifies a checked exception.

    Since:
    1.0
    Author:
    Kevin Bourrillion
    • Method Detail

      • readFully

        void readFully​(byte[] b)
        Specified by:
        readFully in interface java.io.DataInput
      • readFully

        void readFully​(byte[] b,
                       int off,
                       int len)
        Specified by:
        readFully in interface java.io.DataInput
      • skipBytes

        int skipBytes​(int n)
        Specified by:
        skipBytes in interface java.io.DataInput
      • readBoolean

        @CanIgnoreReturnValue
        boolean readBoolean()
        Specified by:
        readBoolean in interface java.io.DataInput
      • readByte

        @CanIgnoreReturnValue
        byte readByte()
        Specified by:
        readByte in interface java.io.DataInput
      • readUnsignedByte

        @CanIgnoreReturnValue
        int readUnsignedByte()
        Specified by:
        readUnsignedByte in interface java.io.DataInput
      • readShort

        @CanIgnoreReturnValue
        short readShort()
        Specified by:
        readShort in interface java.io.DataInput
      • readUnsignedShort

        @CanIgnoreReturnValue
        int readUnsignedShort()
        Specified by:
        readUnsignedShort in interface java.io.DataInput
      • readChar

        @CanIgnoreReturnValue
        char readChar()
        Specified by:
        readChar in interface java.io.DataInput
      • readInt

        @CanIgnoreReturnValue
        int readInt()
        Specified by:
        readInt in interface java.io.DataInput
      • readLong

        @CanIgnoreReturnValue
        long readLong()
        Specified by:
        readLong in interface java.io.DataInput
      • readFloat

        @CanIgnoreReturnValue
        float readFloat()
        Specified by:
        readFloat in interface java.io.DataInput
      • readDouble

        @CanIgnoreReturnValue
        double readDouble()
        Specified by:
        readDouble in interface java.io.DataInput
      • readLine

        @CanIgnoreReturnValue
        @CheckForNull
        java.lang.String readLine()
        Specified by:
        readLine in interface java.io.DataInput
      • readUTF

        @CanIgnoreReturnValue
        java.lang.String readUTF()
        Specified by:
        readUTF in interface java.io.DataInput