public final class Preconditions
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static void |
checkArgument(boolean expression,
java.lang.String errorMessage)
Ensures the truth of an expression involving one or more parameters to the
calling method.
|
static <T> T |
checkNotNull(T obj,
java.lang.String name)
Ensures the object reference is not null.
|
public static <T> T checkNotNull(T obj,
java.lang.String name)
public static void checkArgument(boolean expression,
java.lang.String errorMessage)
expression - a boolean expressionjava.lang.IllegalArgumentException - if expression is false