Class MultipartBodyArgumentBinder
java.lang.Object
io.micronaut.http.server.netty.multipart.MultipartBodyArgumentBinder
- All Implemented Interfaces:
AnnotatedArgumentBinder<Body,
,MultipartBody, HttpRequest<?>> ArgumentBinder<MultipartBody,
,HttpRequest<?>> TypeArgumentBinder<MultipartBody,
,HttpRequest<?>> AnnotatedRequestArgumentBinder<Body,
,MultipartBody> BodyArgumentBinder<MultipartBody>
,NonBlockingBodyArgumentBinder<MultipartBody>
,RequestArgumentBinder<MultipartBody>
,TypedRequestArgumentBinder<MultipartBody>
@Internal
public class MultipartBodyArgumentBinder
extends Object
implements NonBlockingBodyArgumentBinder<MultipartBody>
A
Body
argument binder for a MultipartBody
argument.- Since:
- 1.3.0
- Author:
- James Kleeh
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.micronaut.core.bind.ArgumentBinder
ArgumentBinder.BindingResult<T>
-
Constructor Summary
ConstructorDescriptionMultipartBodyArgumentBinder
(BeanProvider<NettyHttpServerConfiguration> httpServerConfiguration) Default constructor. -
Method Summary
Modifier and TypeMethodDescriptionbind
(ArgumentConversionContext<MultipartBody> context, HttpRequest<?> source) Bind the given argument from the given source.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.micronaut.http.bind.binders.BodyArgumentBinder
getAnnotationType
Methods inherited from interface io.micronaut.http.bind.binders.TypedRequestArgumentBinder
matches, superTypes
-
Constructor Details
-
MultipartBodyArgumentBinder
public MultipartBodyArgumentBinder(BeanProvider<NettyHttpServerConfiguration> httpServerConfiguration) Default constructor.- Parameters:
httpServerConfiguration
- The server configuration
-
-
Method Details
-
argumentType
- Specified by:
argumentType
in interfaceTypeArgumentBinder<MultipartBody,
HttpRequest<?>> - Returns:
- The argument type.
-
bind
public ArgumentBinder.BindingResult<MultipartBody> bind(ArgumentConversionContext<MultipartBody> context, HttpRequest<?> source) Description copied from interface:ArgumentBinder
Bind the given argument from the given source.- Specified by:
bind
in interfaceArgumentBinder<MultipartBody,
HttpRequest<?>> - Parameters:
context
- TheArgumentConversionContext
source
- The source- Returns:
- An
Optional
of the value. If no binding was possibleOptional.empty()
-