public class ArrayUtils
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.Object[] |
EMPTY_OBJECT_ARRAY
An empty object array.
|
Constructor and Description |
---|
ArrayUtils() |
Modifier and Type | Method and Description |
---|---|
static byte[] |
concat(byte[] a,
byte... b)
Concatenate two byte arrays.
|
static <T> T[] |
concat(T[] a,
T... b)
Concatenate two arrays.
|
static boolean |
isEmpty(java.lang.Object[] array)
Whether the given array is empty.
|
static boolean |
isNotEmpty(java.lang.Object[] array)
Whether the given array is not empty.
|
static <T> java.util.Iterator<T> |
iterator(T... array)
Produce an iterator for the given array.
|
static <T> java.util.Iterator<T> |
reverseIterator(T... array)
Produce an iterator for the given array.
|
static java.lang.String |
toString(java.lang.Object[] array)
Produce a string representation of the given array.
|
static java.lang.String |
toString(java.lang.String delimiter,
java.lang.Object[] array)
Produce a string representation of the given array.
|
public static final java.lang.Object[] EMPTY_OBJECT_ARRAY
public static <T> T[] concat(T[] a, T... b)
T
- The array typea
- The first arrayb
- The second arraypublic static byte[] concat(byte[] a, byte... b)
a
- The first arrayb
- The second arraypublic static boolean isEmpty(java.lang.Object[] array)
array
- The arraypublic static boolean isNotEmpty(java.lang.Object[] array)
array
- The arraypublic static java.lang.String toString(@Nullable java.lang.Object[] array)
array
- The arraypublic static java.lang.String toString(java.lang.String delimiter, @Nullable java.lang.Object[] array)
delimiter
- The delimiterarray
- The arraypublic static <T> java.util.Iterator<T> iterator(T... array)
T
- The array typearray
- The arraypublic static <T> java.util.Iterator<T> reverseIterator(T... array)
T
- The array typearray
- The array