Package io.servicetalk.http.utils
Class RequestTargetEncoderHttpServiceFilter
- java.lang.Object
-
- io.servicetalk.http.utils.RequestTargetEncoderHttpServiceFilter
-
- All Implemented Interfaces:
HttpExecutionStrategyInfluencer
,StreamingHttpServiceFilterFactory
public final class RequestTargetEncoderHttpServiceFilter extends java.lang.Object implements StreamingHttpServiceFilterFactory, HttpExecutionStrategyInfluencer
Encodes theHttpRequestMetaData.requestTarget()
for each incoming request.URI producers should encode query strings, but just in case they don't this filter will do the encoding.
-
-
Constructor Summary
Constructors Constructor Description RequestTargetEncoderHttpServiceFilter()
Create a new instance.RequestTargetEncoderHttpServiceFilter(java.nio.charset.Charset charset)
Create a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StreamingHttpServiceFilter
create(StreamingHttpService service)
Create aStreamingHttpServiceFilter
using the providedStreamingHttpService
.HttpExecutionStrategy
influenceStrategy(HttpExecutionStrategy strategy)
Optionally modify the passedHttpExecutionStrategy
to a newHttpExecutionStrategy
that suits thisHttpExecutionStrategyInfluencer
.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.servicetalk.http.api.StreamingHttpServiceFilterFactory
append
-
-
-
-
Constructor Detail
-
RequestTargetEncoderHttpServiceFilter
public RequestTargetEncoderHttpServiceFilter()
Create a new instance.
-
RequestTargetEncoderHttpServiceFilter
public RequestTargetEncoderHttpServiceFilter(java.nio.charset.Charset charset)
Create a new instance.- Parameters:
charset
- The charset to use for the encoding.
-
-
Method Detail
-
create
public StreamingHttpServiceFilter create(StreamingHttpService service)
Description copied from interface:StreamingHttpServiceFilterFactory
Create aStreamingHttpServiceFilter
using the providedStreamingHttpService
.- Specified by:
create
in interfaceStreamingHttpServiceFilterFactory
- Parameters:
service
-StreamingHttpService
to filter- Returns:
StreamingHttpServiceFilter
using the providedStreamingHttpService
.
-
influenceStrategy
public HttpExecutionStrategy influenceStrategy(HttpExecutionStrategy strategy)
Description copied from interface:HttpExecutionStrategyInfluencer
Optionally modify the passedHttpExecutionStrategy
to a newHttpExecutionStrategy
that suits thisHttpExecutionStrategyInfluencer
.- Specified by:
influenceStrategy
in interfaceHttpExecutionStrategyInfluencer
- Parameters:
strategy
-HttpExecutionStrategy
to influence.- Returns:
HttpExecutionStrategy
that suits thisHttpExecutionStrategyInfluencer
-
-