Package org.assertj.core.error
Class ShouldHaveOnlyElementsOfType
- java.lang.Object
-
- org.assertj.core.error.BasicErrorMessageFactory
-
- org.assertj.core.error.ShouldHaveOnlyElementsOfType
-
- All Implemented Interfaces:
ErrorMessageFactory
public class ShouldHaveOnlyElementsOfType extends BasicErrorMessageFactory
Creates an error message indicating that a group does not have an element of the given type.
-
-
Field Summary
-
Fields inherited from class org.assertj.core.error.BasicErrorMessageFactory
arguments, format, formatter
-
-
Constructor Summary
Constructors Modifier Constructor Description private
ShouldHaveOnlyElementsOfType(Object actual, Class<?> expectedType, Class<?> unexpectedType)
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ShouldHaveOnlyElementsOfType
shouldHaveOnlyElementsOfType(Object actual, Class<?> expectedType, Class<?> unexpectedType)
Creates a new
.ShouldHaveOnlyElementsOfType
-
Methods inherited from class org.assertj.core.error.BasicErrorMessageFactory
create, create, create, equals, hashCode, toString, unquotedString
-
-
-
-
Method Detail
-
shouldHaveOnlyElementsOfType
public static ShouldHaveOnlyElementsOfType shouldHaveOnlyElementsOfType(Object actual, Class<?> expectedType, Class<?> unexpectedType)
Creates a new
.ShouldHaveOnlyElementsOfType
- Parameters:
actual
- array or IterableexpectedType
- the expected type of all elementsunexpectedType
- the type of one element that is not expectedType or it subclasses.- Returns:
- the created
ErrorMessageFactory
.
-
-