Class NativeInt8Array

All Implemented Interfaces:
Serializable, Iterable<Byte>, Collection<Byte>, List<Byte>, RandomAccess, SequencedCollection<Byte>, ConstProperties, DebuggableObject, ExternalArrayData, IdFunctionCall, Scriptable

public class NativeInt8Array extends NativeTypedArrayView<Byte>
An array view that stores 8-bit quantities and implements the JavaScript "Int8Array" interface. It also implements List for direct manipulation in Java.
See Also:
  • Constructor Details

    • NativeInt8Array

      public NativeInt8Array()
    • NativeInt8Array

      public NativeInt8Array(NativeArrayBuffer ab, int off, int len)
    • NativeInt8Array

      public NativeInt8Array(int len)
  • Method Details

    • getClassName

      public String getClassName()
      Description copied from class: ScriptableObject
      Return the name of the class. This is typically the same name as the constructor. Classes extending ScriptableObject must implement this abstract method.
      Specified by:
      getClassName in interface Scriptable
      Specified by:
      getClassName in class ScriptableObject
    • init

      public static void init(Context cx, Scriptable scope, boolean sealed)
    • getBytesPerElement

      public int getBytesPerElement()
      Description copied from class: NativeTypedArrayView
      Return the number of bytes represented by each element in the array. This can be useful when wishing to manipulate the byte array directly from Java.
      Specified by:
      getBytesPerElement in class NativeTypedArrayView<Byte>
    • get

      public Byte get(int i)
    • set

      public Byte set(int i, Byte aByte)