List of utility methods to do Array Index Of
int | indexOf(long[] array, long valueToFind, int startIndex) Finds the index of the given value in the array starting at the given index. This method returns #INDEX_NOT_FOUND ( A negative startIndex is treated as zero. if (array == null) { return INDEX_NOT_FOUND; if (startIndex < 0) { startIndex = 0; for (int i = startIndex; i < array.length; i++) { if (valueToFind == array[i]) { ... |
int | indexOf(short[] array, short valueToFind) Finds the index of the given value in the array. This method returns #INDEX_NOT_FOUND ( return indexOf(array, valueToFind, 0);
|
int | indexOf(short[] array, short valueToFind, int startIndex) Finds the index of the given value in the array starting at the given index. This method returns #INDEX_NOT_FOUND ( A negative startIndex is treated as zero. if (array == null) { return INDEX_NOT_FOUND; if (startIndex < 0) { startIndex = 0; for (int i = startIndex; i < array.length; i++) { if (valueToFind == array[i]) { ... |
int | indexOfByReference(T e, T[] array) index Of By Reference for (int i = 0; i != array.length; ++i) { if (array[i] == e) return i; return -1; |