Top Description Fields Constructors Methods
org.assertj.core.error

public Class ShouldHaveAtIndex

extends BasicErrorMessageFactory
Class Inheritance
Imports
java.util.List, org.assertj.core.api.Condition, org.assertj.core.data.Index

Creates an error message indicating that an assertion that verifies a group of elements contains a value at a given index that satisfies a Condition failed.
Author
Bo Gotthardt

Field Summary

Inherited from org.assertj.core.error.BasicErrorMessageFactory:
argumentsformatformatter

Constructor Summary

AccessConstructor and Description
private <T>
ShouldHaveAtIndex(List<? extends T> actual, Condition<? super T> condition, Index index, T found)

Method Summary

Modifier and TypeMethod and Description
public static <
guarantees that the type of the actual value and the generic type of the Condition are the same.
T
>
ErrorMessageFactory

Returns:

the created ErrorMessageFactory.
shouldHaveAtIndex
(List<? extends T>
the actual value in the failed assertion.
actual
,
Condition<? super T>
the Condition.
condition
,
Index
the index of the expected value.
index
,
T
the value in actual stored under index.
found
)

Creates a new ShouldHaveAtIndex.

Inherited from org.assertj.core.error.BasicErrorMessageFactory:
createcreatecreateequalshashCodetoStringunquotedString

Constructor Detail

ShouldHaveAtIndexback to summary
private <T> ShouldHaveAtIndex(List<? extends T> actual, Condition<? super T> condition, Index index, T found)

Method Detail

shouldHaveAtIndexback to summary
public static <T> ErrorMessageFactory shouldHaveAtIndex(List<? extends T> actual, Condition<? super T> condition, Index index, T found)

Creates a new ShouldHaveAtIndex.

Parameters
<T>
guarantees that the type of the actual value and the generic type of the Condition are the same.
actual:List<? extends T>

the actual value in the failed assertion.

condition:Condition<? super T>

the Condition.

index:Index

the index of the expected value.

found:T

the value in actual stored under index.

Returns:ErrorMessageFactory

the created ErrorMessageFactory.