Class ShortArrayCodeInput

java.lang.Object
com.android.dx.io.instructions.BaseCodeCursor
com.android.dx.io.instructions.ShortArrayCodeInput
All Implemented Interfaces:
CodeCursor, CodeInput

public final class ShortArrayCodeInput extends BaseCodeCursor implements CodeInput
Implementation of CodeInput that reads from a short[].
  • Constructor Details

    • ShortArrayCodeInput

      public ShortArrayCodeInput(short[] array)
      Constructs an instance.
  • Method Details

    • hasMore

      public boolean hasMore()
      Returns whether there are any more code units to read. This is analogous to hasNext() on an interator.
      Specified by:
      hasMore in interface CodeInput
    • read

      public int read() throws EOFException
      Reads a code unit.
      Specified by:
      read in interface CodeInput
      Throws:
      EOFException
    • readInt

      public int readInt() throws EOFException
      Reads two code units, treating them as a little-endian int.
      Specified by:
      readInt in interface CodeInput
      Throws:
      EOFException
    • readLong

      public long readLong() throws EOFException
      Reads four code units, treating them as a little-endian long.
      Specified by:
      readLong in interface CodeInput
      Throws:
      EOFException