- notNull
Assert that an object is not null .
Assert.notNull(clazz, "The class must not be null");
- hasText
Assert that the given String has valid text content; that is, it must not be
null and must contain a
- isTrue
Assert a boolean expression, throwing IllegalArgumentException if the test
result is false.
Assert.
- notEmpty
Assert that an array has elements; that is, it must not be nulland must have at
least one element.
- state
Assert a boolean expression, throwing IllegalStateException if the test result
is false. Call isTrue
- hasLength
Assert that the given String is not empty; that is, it must not be null and not
the empty String.
A
- isAssignable
Assert that superType.isAssignableFrom(subType) is true.
Assert.isAssignable(Number.class, myClass)
- isInstanceOf
Assert that the provided object is an instance of the provided class.
Assert.instanceOf(Foo.class,
- isNull
Assert that an object is null .
Assert.isNull(value, "The value must be null");
- noNullElements
Assert that an array has no null elements. Note: Does not complain if the array
is empty!
Assert.no