Package com.linecorp.armeria.client
Class AbstractRuleWithContentBuilder<T extends Response>
java.lang.Object
com.linecorp.armeria.client.AbstractRuleBuilder
com.linecorp.armeria.client.AbstractRuleWithContentBuilder<T>
- Type Parameters:
T
- the response type
- Direct Known Subclasses:
CircuitBreakerRuleWithContentBuilder
,RetryRuleWithContentBuilder
@UnstableApi
public abstract class AbstractRuleWithContentBuilder<T extends Response>
extends AbstractRuleBuilder
A skeletal builder implementation for
RetryRuleWithContent
and CircuitBreakerRuleWithContent
.-
Constructor Summary
ModifierConstructorDescriptionprotected
AbstractRuleWithContentBuilder
(BiPredicate<? super ClientRequestContext, ? super RequestHeaders> requestHeadersFilter) Creates a new instance with the specifiedrequestHeadersFilter
. -
Method Summary
Modifier and TypeMethodDescriptiononResponse
(BiFunction<? super ClientRequestContext, ? super T, ? extends CompletionStage<Boolean>> responseFilter) Adds the specifiedresponseFilter
.protected final @Nullable BiFunction<? super ClientRequestContext,
? super T, ? extends CompletionStage<Boolean>> Returns theresponseFilter
.Methods inherited from class com.linecorp.armeria.client.AbstractRuleBuilder
exceptionFilter, onException, onException, onException, onResponseHeaders, onResponseTrailers, onServerErrorStatus, onStatus, onStatus, onStatus, onStatusClass, onStatusClass, onUnprocessed, requestHeadersFilter, responseHeadersFilter, responseTrailersFilter
-
Constructor Details
-
AbstractRuleWithContentBuilder
protected AbstractRuleWithContentBuilder(BiPredicate<? super ClientRequestContext, ? super RequestHeaders> requestHeadersFilter) Creates a new instance with the specifiedrequestHeadersFilter
.
-
-
Method Details
-
onResponse
public AbstractRuleWithContentBuilder<T> onResponse(BiFunction<? super ClientRequestContext, ? super T, ? extends CompletionStage<Boolean>> responseFilter) Adds the specifiedresponseFilter
. -
responseFilter
@Nullable protected final @Nullable BiFunction<? super ClientRequestContext,? super T, responseFilter()? extends CompletionStage<Boolean>> Returns theresponseFilter
.
-