public static <T> T[] noNullElements(T[] array, String message, Object... values) {
        Validate.notNull(array);
        for (int i = 0; i < array.length; i++) {
            if (array[i] == null) {
                Object[] values2 = ArrayUtils.add(values, Integer.valueOf(i));
                throw new IllegalArgumentException(String.format(message, values2));
            }
        }
        return array;
    }
<p>Validate that the specified argument array is neither
{@code null} nor contains any elements that are {@code null};
otherwise throwing an exception with the specified message.

<pre>Validate.noNullElements(myArray, "The array contain null at position %d");</pre>

<p>If the array is {@code null}, then the message in the exception
is &quot;The validated object is null&quot;.</p>

<p>If the array has a {@code null} element, then the iteration
index of the invalid element is appended to the {@code values}
argument.</p>

@param <T> the array type
@param array  the array to check, validated not null by this method
@param message  the {@link String#format(String, Object...)} exception message if invalid, not null
@param values  the optional values for the formatted exception message, null array not recommended
@return the validated array (never {@code null} method for chaining)
@throws NullPointerException if the array is {@code null}
@throws IllegalArgumentException if an element is {@code null}
@see #noNullElements(Object[])
android/android_framework/base/src/main/java/lang3/Validate.java