public class PublisherBodyBinder extends DefaultBodyAnnotationBinder<org.reactivestreams.Publisher> implements NonBlockingBodyArgumentBinder<org.reactivestreams.Publisher>
Body
argument binder for a reactive streams Publisher
.ArgumentBinder.BindingResult<T>
conversionService
Constructor and Description |
---|
PublisherBodyBinder(ConversionService conversionService,
HttpContentProcessorResolver httpContentProcessorResolver) |
Modifier and Type | Method and Description |
---|---|
Argument<org.reactivestreams.Publisher> |
argumentType() |
ArgumentBinder.BindingResult<org.reactivestreams.Publisher> |
bind(ArgumentConversionContext<org.reactivestreams.Publisher> context,
HttpRequest<?> source)
Bind the given argument from the given source.
|
boolean |
supportsSuperTypes()
Determines whether arguments that are an interface that
T
implements are candidates for binding. |
getAnnotationType
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getAnnotationType
of
superTypes
public PublisherBodyBinder(ConversionService conversionService, HttpContentProcessorResolver httpContentProcessorResolver)
conversionService
- The conversion servicehttpContentProcessorResolver
- The http content processor resolverpublic boolean supportsSuperTypes()
TypedRequestArgumentBinder
T
implements are candidates for binding.supportsSuperTypes
in interface TypedRequestArgumentBinder<org.reactivestreams.Publisher>
public Argument<org.reactivestreams.Publisher> argumentType()
argumentType
in interface TypeArgumentBinder<org.reactivestreams.Publisher,HttpRequest<?>>
public ArgumentBinder.BindingResult<org.reactivestreams.Publisher> bind(ArgumentConversionContext<org.reactivestreams.Publisher> context, HttpRequest<?> source)
ArgumentBinder
bind
in interface ArgumentBinder<org.reactivestreams.Publisher,HttpRequest<?>>
bind
in class DefaultBodyAnnotationBinder<org.reactivestreams.Publisher>
context
- The ArgumentConversionContext
source
- The sourceOptional
of the value. If no binding was possible Optional.empty()