Package io.helidon.common.reactive
Class ReactiveStreamsAdapter
- java.lang.Object
-
- io.helidon.common.reactive.ReactiveStreamsAdapter
-
public final class ReactiveStreamsAdapter extends Object
Static utility methods for converting between Helidon reactive APIFlowand reactive-streams.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <T> reactor.core.publisher.Flux<T>publisherFromFlow(Flow.Publisher<T> publisher)Return aPublisherfrom aFlow.Publisher.static <T> Flow.Publisher<T>publisherToFlow(Publisher<T> publisher)Return aFlow.Publisherfrom aPublisher.static <T> Subscriber<T>subscriberFromFlow(Flow.Subscriber<T> subscriber)Return aSubscriberfrom aFlow.Subscriber.static <T> Flow.Subscriber<T>subscriberToFlow(Subscriber<T> subscriber)Return aFlow.Subscriberfrom aSubscriber.
-
-
-
Method Detail
-
publisherToFlow
public static <T> Flow.Publisher<T> publisherToFlow(Publisher<T> publisher)
Return aFlow.Publisherfrom aPublisher.- Type Parameters:
T- the type of the publisher- Parameters:
publisher- the source Publisher to convert- Returns:
- a
Flow.Publisher
-
publisherFromFlow
public static <T> reactor.core.publisher.Flux<T> publisherFromFlow(Flow.Publisher<T> publisher)
Return aPublisherfrom aFlow.Publisher.- Type Parameters:
T- the type of the publisher- Parameters:
publisher- the source Publisher to convert- Returns:
- a
Flux
-
subscriberToFlow
public static <T> Flow.Subscriber<T> subscriberToFlow(Subscriber<T> subscriber)
Return aFlow.Subscriberfrom aSubscriber.- Type Parameters:
T- the type of the subscriber- Parameters:
subscriber- the source Subscriber to convert- Returns:
- a
Subscriber
-
subscriberFromFlow
public static <T> Subscriber<T> subscriberFromFlow(Flow.Subscriber<T> subscriber)
Return aSubscriberfrom aFlow.Subscriber.- Type Parameters:
T- the type of the subscriber- Parameters:
subscriber- the source Subscriber to convert- Returns:
- a
Flow.Subscriber
-
-