@Provider public class MonoProvider extends Object implements AsyncResponseProvider<reactor.core.publisher.Mono<?>>, AsyncClientResponseProvider<reactor.core.publisher.Mono<?>>
| Constructor and Description |
|---|
MonoProvider() |
| Modifier and Type | Method and Description |
|---|---|
reactor.core.publisher.Mono<?> |
fromCompletionStage(CompletionStage<?> completionStage)
Turns
CompletionStage to a reactive type. |
reactor.core.publisher.Mono<?> |
fromCompletionStage(Supplier<CompletionStage<?>> completionStageSupplier)
Turns
CompletionStage to a reactive type in a deferred fashion. |
CompletionStage<?> |
toCompletionStage(reactor.core.publisher.Mono<?> asyncResponse) |
public CompletionStage<?> toCompletionStage(reactor.core.publisher.Mono<?> asyncResponse)
toCompletionStage in interface AsyncResponseProvider<reactor.core.publisher.Mono<?>>public reactor.core.publisher.Mono<?> fromCompletionStage(CompletionStage<?> completionStage)
AsyncClientResponseProviderCompletionStage to a reactive type.fromCompletionStage in interface AsyncClientResponseProvider<reactor.core.publisher.Mono<?>>completionStage - The CompletionStage that will produce a value.public reactor.core.publisher.Mono<?> fromCompletionStage(Supplier<CompletionStage<?>> completionStageSupplier)
AsyncClientResponseProviderCompletionStage to a reactive type in a deferred fashion. For instance, in the case of
Rx or Reactor, the Supplier.get() will only be called when subscription happens.fromCompletionStage in interface AsyncClientResponseProvider<reactor.core.publisher.Mono<?>>completionStageSupplier - The Supplier of a CompletionStage that will produce a value.
This allows lazy triggering of future-based APIs.Copyright © 2020 JBoss by Red Hat. All rights reserved.