com.github.dreamhead.bot.util.Preconditions Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of bot-core Show documentation
Show all versions of bot-core Show documentation
Object bot is a library for setting up Java objects as test data.
The newest version!
package com.github.dreamhead.bot.util;
import java.util.Objects;
public final class Preconditions {
public static T[] checkNotNullElements(final T[] array, final String message) {
if (array != null) {
for (T element : array) {
Objects.requireNonNull(element, message);
}
}
return array;
}
private Preconditions() {
}
}