public class DefaultReactorHttpClient extends Object implements ReactorHttpClient
| 限定符和类型 | 方法和说明 |
|---|---|
protected <T> org.asynchttpclient.AsyncHandler<?> |
createBridge(DisposableMonoSink<T> emitter,
org.asynchttpclient.AsyncHandler<T> handler)
Creates an
AsyncHandler that bridges events from the given
handler to the given emitter and cancellation/disposal in the
other direction. |
<T> reactor.core.publisher.Mono<T> |
prepare(org.asynchttpclient.Request request,
org.asynchttpclient.AsyncHandler<T> handler)
disposable 主要监控 是否取消, 取消之后 AsyncHandler 怎么应对
onDispose 是一个回调, 会通过 disposable 来 取消 disposable 中需要取消的资源
-- 上层不会取消, 做一个简单的监控
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcreatepublic <T> reactor.core.publisher.Mono<T> prepare(org.asynchttpclient.Request request,
org.asynchttpclient.AsyncHandler<T> handler)
prepare 在接口中 ReactorHttpClientT - the result type produced by handlers produced by
handlerSupplier and emitted by the returned Maybe
instancerequest - the request that is to be executedMaybe that executes request upon subscription and
that emits the results produced by the supplied handersprotected <T> org.asynchttpclient.AsyncHandler<?> createBridge(DisposableMonoSink<T> emitter, org.asynchttpclient.AsyncHandler<T> handler)
AsyncHandler that bridges events from the given
handler to the given emitter and cancellation/disposal in the
other direction.T - the result type produced by handler and emitted by
emitteremitter - the RxJava emitter instance that receives results upon completion
and will be queried for disposal during event processinghandler - the AsyncHandler instance that receives downstream events
and produces the result that will be emitted upon request
completionCopyright © 2020. All rights reserved.