Class SplittingTransformer.Builder<ResponseT,ResultT>
- java.lang.Object
-
- software.amazon.awssdk.core.internal.async.SplittingTransformer.Builder<ResponseT,ResultT>
-
- Enclosing class:
- SplittingTransformer<ResponseT,ResultT>
public static final class SplittingTransformer.Builder<ResponseT,ResultT> extends Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SplittingTransformer<ResponseT,ResultT>build()SplittingTransformer.Builder<ResponseT,ResultT>maximumBufferSizeInBytes(Long maximumBufferSize)The amount of data in byte this publisher will buffer into memory before sending it to the upstream transformer.SplittingTransformer.Builder<ResponseT,ResultT>resultFuture(CompletableFuture<ResultT> returnFuture)The future that will be completed when the future which is returned by the call toAsyncResponseTransformer.prepare()completes.SplittingTransformer.Builder<ResponseT,ResultT>upstreamResponseTransformer(AsyncResponseTransformer<ResponseT,ResultT> upstreamResponseTransformer)TheAsyncResponseTransformerthat will receive the data from each of the individually publishedIndividualTransformer, usually intended to be the one on which theAsyncResponseTransformer.split(SplittingTransformerConfiguration))} method was called.
-
-
-
Method Detail
-
upstreamResponseTransformer
public SplittingTransformer.Builder<ResponseT,ResultT> upstreamResponseTransformer(AsyncResponseTransformer<ResponseT,ResultT> upstreamResponseTransformer)
TheAsyncResponseTransformerthat will receive the data from each of the individually publishedIndividualTransformer, usually intended to be the one on which theAsyncResponseTransformer.split(SplittingTransformerConfiguration))} method was called.- Parameters:
upstreamResponseTransformer- theAsyncResponseTransformerthat was split.- Returns:
- an instance of this builder
-
maximumBufferSizeInBytes
public SplittingTransformer.Builder<ResponseT,ResultT> maximumBufferSizeInBytes(Long maximumBufferSize)
The amount of data in byte this publisher will buffer into memory before sending it to the upstream transformer. The data will be sent if chunk ofmaximumBufferSizeto the upstream transformer unless the subscription is cancelled while less amount is buffered, in which case a chunk with a size less thanmaximumBufferSizewill be sent.- Parameters:
maximumBufferSize- the amount of data buffered and the size of the chunk of data- Returns:
- an instance of this builder
-
resultFuture
public SplittingTransformer.Builder<ResponseT,ResultT> resultFuture(CompletableFuture<ResultT> returnFuture)
The future that will be completed when the future which is returned by the call toAsyncResponseTransformer.prepare()completes.- Parameters:
returnFuture- the future to complete.- Returns:
- an instance of this builder
-
build
public SplittingTransformer<ResponseT,ResultT> build()
-
-