public class ArrayUtil extends Object
| Constructor and Description |
|---|
ArrayUtil() |
| Modifier and Type | Method and Description |
|---|---|
static int[] |
addAllInt(int[] array1,
int[] array2) |
static long[] |
addAllLong(long[] array1,
long[] array2) |
static Object[] |
addAllObj(Object[] array1,
Object[] array2) |
static void |
addInt(int[] array,
int val) |
static int[] |
cloneInt(int[] array) |
static long[] |
cloneLong(long[] array) |
static Object[] |
cloneObj(Object[] array) |
static byte[][] |
create2D(int width,
int height) |
static int |
max(int[] array) |
static byte[] |
padLeft(byte[] array,
int padLength) |
static void |
printMatrix(byte[] array,
String format,
int width) |
static void |
printMatrix(int[] array,
String format,
int width) |
static void |
quickSort(int[] a,
int start,
int end,
int[] p)
Implements a quicksort algorithm
|
static byte[] |
randomByteArray(int size,
byte from,
byte to) |
static int[] |
randomIntArray(int size,
int from,
int to) |
static <T> void |
reverse(T[] frames) |
static int[][] |
rotate(int[][] src) |
static <T> void |
shiftLeft1(T[] array) |
static <T> void |
shiftLeft2(T[] array,
int from) |
static <T> void |
shiftLeft3(T[] array,
int from,
int to) |
static <T> void |
shiftRight1(T[] array) |
static <T> void |
shiftRight2(T[] array,
int to) |
static <T> void |
shiftRight3(T[] array,
int from,
int to) |
static int |
sumByte(byte[] array) |
static int |
sumByte3(byte[] array,
int from,
int count) |
static int |
sumInt(int[] array) |
static int |
sumInt3(int[] array,
int from,
int count) |
static void |
swap(int[] arr,
int ind1,
int ind2) |
static byte[] |
toByteArray(int... arguments) |
static byte[] |
toByteArrayShifted(int... arguments) |
static byte[][] |
toByteArrayShifted2(int[][] intArray) |
static int[] |
toIntArray(byte... arguments) |
static int[] |
toIntArrayUnshifted(byte... arguments) |
static int[] |
toUnsignedIntArray(byte[] val) |
public static <T> void shiftRight1(T[] array)
public static <T> void shiftLeft1(T[] array)
public static <T> void shiftRight3(T[] array,
int from,
int to)
public static <T> void shiftLeft3(T[] array,
int from,
int to)
public static <T> void shiftLeft2(T[] array,
int from)
public static <T> void shiftRight2(T[] array,
int to)
public static final void swap(int[] arr,
int ind1,
int ind2)
public static final int sumInt(int[] array)
public static final int sumByte(byte[] array)
public static int sumInt3(int[] array,
int from,
int count)
public static int sumByte3(byte[] array,
int from,
int count)
public static void addInt(int[] array,
int val)
public static int[] addAllInt(int[] array1,
int[] array2)
public static long[] addAllLong(long[] array1,
long[] array2)
public static int[] cloneInt(int[] array)
public static long[] cloneLong(long[] array)
public static byte[] toByteArrayShifted(int... arguments)
public static byte[][] toByteArrayShifted2(int[][] intArray)
public static int[] toIntArrayUnshifted(byte... arguments)
public static byte[] toByteArray(int... arguments)
public static int[] toIntArray(byte... arguments)
public static int[] toUnsignedIntArray(byte[] val)
public static <T> void reverse(T[] frames)
public static int max(int[] array)
public static int[][] rotate(int[][] src)
public static byte[][] create2D(int width,
int height)
public static void printMatrix(byte[] array,
String format,
int width)
public static void printMatrix(int[] array,
String format,
int width)
public static byte[] padLeft(byte[] array,
int padLength)
public static int[] randomIntArray(int size,
int from,
int to)
public static byte[] randomByteArray(int size,
byte from,
byte to)
public static void quickSort(int[] a,
int start,
int end,
int[] p)
Copyright © 2018. All rights reserved.