T
- The type of result of the CompletableFuture
WaitResultBuilder1<T>
public interface WaitResultBuilder2<T>
CompletableFuture
to specify the
condition to accept a result.Modifier and Type | Method | Description |
---|---|---|
WaitResultBuilder3<T> |
expecting(Predicate<T> acceptingClause) |
Specify the condition that accept the result.
|
default WaitResultBuilder3<T> |
expectingAllOf(Predicate<T> acceptingClause1,
Predicate<T>... next) |
Specify that at all conditions must accept the result.
|
default WaitResultBuilder3<T> |
expectingAnyOf(Predicate<T> acceptingClause1,
Predicate<T>... next) |
Specify that at least one condition must accept the result.
|
default WaitResultBuilder3<T> |
expectingEqualsTo(T other) |
Specify that the returned result must be equals to the received object.
|
default WaitResultBuilder3<T> |
expectingNot(Predicate<T> notAcceptingClause) |
Specify the condition that doesn't accept the result.
|
default WaitResultBuilder3<T> |
expectingNotNull() |
Specify that the returned result must be not null.
|
WaitResultBuilder3<T> expecting(Predicate<T> acceptingClause)
acceptingClause
- the Predicate
to validate the resultthe next step of the builder
default WaitResultBuilder3<T> expectingEqualsTo(T other)
other
- the object to compare with. May be null.the next step of the builder
Predicate.isEqual(Object)
default WaitResultBuilder3<T> expectingNotNull()
the next step of the builder
Objects.nonNull(Object)
default WaitResultBuilder3<T> expectingNot(Predicate<T> notAcceptingClause)
notAcceptingClause
- the Predicate
to validate the resultthe next step of the builder
default WaitResultBuilder3<T> expectingAnyOf(Predicate<T> acceptingClause1, Predicate<T>... next)
acceptingClause1
- first condition
to accept the result.next
- all the following condition to accept the result.the next step of the builder
default WaitResultBuilder3<T> expectingAllOf(Predicate<T> acceptingClause1, Predicate<T>... next)
acceptingClause1
- first condition
to accept the result.next
- all the following condition to accept the result.the next step of the builder
Copyright © 2021. All rights reserved.