Package ru.tinkoff.kora.common.util
Class FlowUtils
java.lang.Object
ru.tinkoff.kora.common.util.FlowUtils
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T> Flow.Subscriber<T>drain()static <T> Flow.Publisher<T>static <T> Flow.Publisher<T>static <T> Flow.Publisher<T>fromCallable(Context context, Callable<T> value) static <T> Flow.Publisher<T>static CompletableFuture<byte[]>toByteArrayFuture(Flow.Publisher<? extends ByteBuffer> publisher) static CompletableFuture<byte[]>toByteArrayFuture(Flow.Publisher<? extends ByteBuffer> publisher, int maxLength) static CompletableFuture<ByteBuffer>toByteBufferFuture(Flow.Publisher<? extends ByteBuffer> publisher) static CompletableFuture<ByteBuffer>toByteBufferFuture(Flow.Publisher<? extends ByteBuffer> publisher, int maxLength) static <T> CompletionStage<T>toFuture(Flow.Publisher<T> publisher)
-
Method Details
-
toFuture
-
empty
-
one
-
fromCallable
-
error
-
drain
-
toByteArrayFuture
public static CompletableFuture<byte[]> toByteArrayFuture(Flow.Publisher<? extends ByteBuffer> publisher) -
toByteArrayFuture
public static CompletableFuture<byte[]> toByteArrayFuture(Flow.Publisher<? extends ByteBuffer> publisher, int maxLength) -
toByteBufferFuture
public static CompletableFuture<ByteBuffer> toByteBufferFuture(Flow.Publisher<? extends ByteBuffer> publisher) -
toByteBufferFuture
public static CompletableFuture<ByteBuffer> toByteBufferFuture(Flow.Publisher<? extends ByteBuffer> publisher, int maxLength)
-