Java org.springframework.util Assert fields, constructors, methods, implement or subclass

Example usage for Java org.springframework.util Assert fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for org.springframework.util Assert.

The text is from its open source code.

Subclass

org.springframework.util.Assert has subclasses.
Click this link to see all its subclasses.

Method

voiddoesNotContain(@Nullable String textToSearch, String substring, String message)
Assert that the given text does not contain the given substring.
voiddoesNotContain(@Nullable String textToSearch, String substring, Supplier messageSupplier)
Assert that the given text does not contain the given substring.
voiddoesNotContain(@Nullable String textToSearch, String substring)
Assert that the given text does not contain the given substring.
voidhasLength(@Nullable String text)
Assert that the given String is not empty; that is, it must not be null and not the empty String.
voidhasLength(@Nullable String text, String message)
Assert that the given String is not empty; that is, it must not be null and not the empty String.
voidhasLength(@Nullable String text, Supplier messageSupplier)
Assert that the given String is not empty; that is, it must not be null and not the empty String.
voidhasText(@Nullable String text)
Assert that the given String contains valid text content; that is, it must not be null and must contain at least one non-whitespace character.
voidhasText(@Nullable String text, String message)
Assert that the given String contains valid text content; that is, it must not be null and must contain at least one non-whitespace character.
voidhasText(@Nullable String text, Supplier messageSupplier)
Assert that the given String contains valid text content; that is, it must not be null and must contain at least one non-whitespace character.
voidisAssignable(Class superType, Class subType)
Assert that superType.isAssignableFrom(subType) is true .
voidisAssignable(Class superType, @Nullable Class subType, String message)
Assert that superType.isAssignableFrom(subType) is true .
voidisAssignable(Class superType, @Nullable Class subType, Supplier messageSupplier)
Assert that superType.isAssignableFrom(subType) is true .
voidisInstanceOf(Class type, @Nullable Object obj, String message)
Assert that the provided object is an instance of the provided class.
voidisInstanceOf(Class type, @Nullable Object obj, Supplier messageSupplier)
Assert that the provided object is an instance of the provided class.
voidisInstanceOf(Class type, @Nullable Object obj)
Assert that the provided object is an instance of the provided class.
voidisNull(@Nullable Object object)
Assert that an object is null .
voidisNull(@Nullable Object object, String message)
Assert that an object is null .
voidisNull(@Nullable Object object, Supplier messageSupplier)
Assert that an object is null .
voidisTrue(boolean expression, String message)
Assert a boolean expression, throwing an IllegalArgumentException if the expression evaluates to false .
voidisTrue(boolean expression, Supplier messageSupplier)
Assert a boolean expression, throwing an IllegalArgumentException if the expression evaluates to false .
voidisTrue(boolean expression)
Assert a boolean expression, throwing an IllegalArgumentException if the expression evaluates to false .
voidnoNullElements(@Nullable Object[] array)
Assert that an array contains no null elements.
voidnoNullElements(@Nullable Object[] array, String message)
Assert that an array contains no null elements.
voidnoNullElements(@Nullable Object[] array, Supplier messageSupplier)
Assert that an array contains no null elements.
voidnoNullElements(@Nullable Collection collection, String message)
Assert that a collection contains no null elements.
voidnoNullElements(@Nullable Collection collection, Supplier messageSupplier)
Assert that a collection contains no null elements.
voidnotEmpty(@Nullable Object[] array, String message)
Assert that an array contains elements; that is, it must not be null and must contain at least one element.
voidnotEmpty(@Nullable Object[] array, Supplier messageSupplier)
Assert that an array contains elements; that is, it must not be null and must contain at least one element.
voidnotEmpty(@Nullable Collection collection, String message)
Assert that a collection contains elements; that is, it must not be null and must contain at least one element.
voidnotEmpty(@Nullable Collection collection, Supplier messageSupplier)
Assert that a collection contains elements; that is, it must not be null and must contain at least one element.
voidnotEmpty(@Nullable Map map, String message)
Assert that a Map contains entries; that is, it must not be null and must contain at least one entry.
voidnotEmpty(@Nullable Map map, Supplier messageSupplier)
Assert that a Map contains entries; that is, it must not be null and must contain at least one entry.
voidnotEmpty(@Nullable Object[] array)
Assert that an array contains elements; that is, it must not be null and must contain at least one element.
voidnotEmpty(@Nullable Collection collection)
Assert that a collection contains elements; that is, it must not be null and must contain at least one element.
voidnotEmpty(@Nullable Map map)
Assert that a Map contains entries; that is, it must not be null and must contain at least one entry.
voidnotNull(@Nullable Object object)
Assert that an object is not null .
voidnotNull(@Nullable Object object, String message)
Assert that an object is not null .
voidnotNull(@Nullable Object object, Supplier messageSupplier)
Assert that an object is not null .
voidstate(boolean expression)
Assert a boolean expression, throwing an IllegalStateException if the expression evaluates to false .
voidstate(boolean expression, String message)
Assert a boolean expression, throwing an IllegalStateException if the expression evaluates to false .
voidstate(boolean expression, Supplier messageSupplier)
Assert a boolean expression, throwing an IllegalStateException if the expression evaluates to false .