public final class ArrayUtils
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static <T> T[] |
combine(T[] array1,
T[] array2)
The combine() static method combines the contents of two arrays into a single array of the same type.
|
static <T> T[] |
combine(T[] array1,
T[] array2,
int maxElements)
The combine() static method combines the contents of two arrays into a single array of the same type that contains
no more than the maxElements number of elements.
|
public static <T> T[] combine(T[] array1, T[] array2)
T
- the type of arrayarray1
- the array to be concatenated on the leftarray2
- the array to be concatenated on the rightpublic static <T> T[] combine(T[] array1, T[] array2, int maxElements)
T
- the type of arrayarray1
- the array to be concatenated on the leftarray2
- the array to be concatenated on the rightmaxElements
- the maximum number of elements in the resulting array