T - the output value typepublic interface SynchronousSink<T>
Subscriber.
At most one next(T) call and/or one complete() or
error(Throwable) should be called per invocation of the generator function.
Calling a SynchronousSink outside of a generator consumer or function, e.g.
using an async callback, is forbidden. You can FluxSink or
MonoSink based generators for these situations.
| Modifier and Type | Method and Description |
|---|---|
void |
complete() |
Context |
currentContext()
Return the current subscriber
Context. |
void |
error(Throwable e) |
void |
next(T t)
Try emitting, might throw an unchecked exception.
|
void complete()
Subscriber.onComplete()Context currentContext()
Context.
Context can be enriched via Mono.contextWrite(Function)
or Flux.contextWrite(Function)
operator or directly by a child subscriber overriding
CoreSubscriber.currentContext()
Context.void error(Throwable e)
e - the exception to signal, not nullSubscriber.onError(Throwable)void next(T t)
t - the value to emit, not nullRuntimeException - in case of unchecked error during the emissionSubscriber.onNext(Object)