This class provides methods to dynamically create and access arrays.
Static Public Member Functions | |
static native Object | get (Object array, int index) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Return the element of the array at the specified index. | |
static native boolean | getBoolean (Object array, int index) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Return the element of the array at the specified index, converted to a boolean if possible. | |
static native byte | getByte (Object array, int index) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Return the element of the array at the specified index, converted to a byte if possible. | |
static native char | getChar (Object array, int index) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Return the element of the array at the specified index, converted to a char if possible. | |
static native double | getDouble (Object array, int index) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Return the element of the array at the specified index, converted to a double if possible. | |
static native float | getFloat (Object array, int index) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Return the element of the array at the specified index, converted to a float if possible. | |
static native int | getInt (Object array, int index) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Return the element of the array at the specified index, converted to an int if possible. | |
static native int | getLength (Object array) throws IllegalArgumentException |
Return the length of the array. | |
static native long | getLong (Object array, int index) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Return the element of the array at the specified index, converted to a long if possible. | |
static native short | getShort (Object array, int index) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Return the element of the array at the specified index, converted to a short if possible. | |
static Object | newInstance (Class componentType, int[] dimensions) throws NegativeArraySizeException, IllegalArgumentException |
Return a new multidimensional array of the specified component type and dimensions. | |
static Object | newInstance (Class componentType, int size) throws NegativeArraySizeException |
Return a new array of the specified component type and length. | |
static native void | set (Object array, int index, Object value) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Set the element of the array at the specified index to the value. | |
static native void | setBoolean (Object array, int index, boolean value) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Set the element of the array at the specified index to the boolean value. | |
static native void | setByte (Object array, int index, byte value) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Set the element of the array at the specified index to the byte value. | |
static native void | setChar (Object array, int index, char value) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Set the element of the array at the specified index to the char value. | |
static native void | setDouble (Object array, int index, double value) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Set the element of the array at the specified index to the double value. | |
static native void | setFloat (Object array, int index, float value) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Set the element of the array at the specified index to the float value. | |
static native void | setInt (Object array, int index, int value) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Set the element of the array at the specified index to the int value. | |
static native void | setLong (Object array, int index, long value) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Set the element of the array at the specified index to the long value. | |
static native void | setShort (Object array, int index, short value) throws IllegalArgumentException, ArrayIndexOutOfBoundsException |
Set the element of the array at the specified index to the short value. | |
Static Private Member Functions | |
static native Object | multiNewArrayImpl (Class componentType, int dimensions, int[] dimensionsArray) |
static native Object | newArrayImpl (Class componentType, int dimension) |
|
Return the element of the array at the specified index.
This reproduces the effect of
|
|
Return the element of the array at the specified index, converted to a boolean if possible.
This reproduces the effect of
|
|
Return the element of the array at the specified index, converted to a byte if possible.
This reproduces the effect of
|
|
Return the element of the array at the specified index, converted to a char if possible.
This reproduces the effect of
|
|
Return the element of the array at the specified index, converted to a double if possible.
This reproduces the effect of
|
|
Return the element of the array at the specified index, converted to a float if possible.
This reproduces the effect of
|
|
Return the element of the array at the specified index, converted to an int if possible.
This reproduces the effect of
|
|
Return the length of the array.
This reproduces the effect of
|
|
Return the element of the array at the specified index, converted to a long if possible.
This reproduces the effect of
|
|
Return the element of the array at the specified index, converted to a short if possible.
This reproduces the effect of
|
|
Return a new multidimensional array of the specified component type and dimensions.
This reproduces the effect of
|
|
Return a new array of the specified component type and length.
This reproduces the effect of
|
|
Set the element of the array at the specified index to the value.
This reproduces the effect of
|
|
Set the element of the array at the specified index to the boolean value.
This reproduces the effect of
|
|
Set the element of the array at the specified index to the byte value.
This reproduces the effect of
|
|
Set the element of the array at the specified index to the char value.
This reproduces the effect of
|
|
Set the element of the array at the specified index to the double value.
This reproduces the effect of
|
|
Set the element of the array at the specified index to the float value.
This reproduces the effect of
|
|
Set the element of the array at the specified index to the int value.
This reproduces the effect of
|
|
Set the element of the array at the specified index to the long value.
This reproduces the effect of
|
|
Set the element of the array at the specified index to the short value.
This reproduces the effect of
|