Package org.assertj.core.internal
Class ElementsSatisfyingConsumer<E>
- java.lang.Object
-
- org.assertj.core.internal.ElementsSatisfyingConsumer<E>
-
- Type Parameters:
E
- element type
class ElementsSatisfyingConsumer<E> extends Object
Wrapper for the list of elements that satisfy certain requirements (expressed as aConsumer
).- Author:
- Michael Grafl
-
-
Constructor Summary
Constructors Modifier Constructor Description (package private)
ElementsSatisfyingConsumer(Iterable<? extends E> actual, Consumer<? super E> assertions)
private
ElementsSatisfyingConsumer(List<E> elements)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description private static <E> List<E>
filterByPassingAssertions(Iterable<? extends E> actual, Consumer<? super E> assertions)
(package private) List<E>
getElements()
(package private) ElementsSatisfyingConsumer<E>
withoutElement(E element)
NewElementsSatisfyingConsumer
containing all elements except the (first occurrence of the) given element.
-
-
-
Method Detail
-
withoutElement
ElementsSatisfyingConsumer<E> withoutElement(E element)
NewElementsSatisfyingConsumer
containing all elements except the (first occurrence of the) given element.This instance is not modified.
- Parameters:
element
- the element to remove from the result- Returns:
- all except the given element
-
-