public class SynchronossPartHttpMessageReader extends java.lang.Object implements HttpMessageReader<Part>
HttpMessageReader
for parsing "multipart/form-data"
requests
to a stream of Part
's using the Synchronoss NIO Multipart library.
This reader can be provided to MultipartHttpMessageReader
in order
to aggregate all parts into a Map.
MultipartHttpMessageReader
Modifier and Type | Class and Description |
---|---|
private static class |
SynchronossPartHttpMessageReader.AbstractSynchronossPart |
private static class |
SynchronossPartHttpMessageReader.DefaultSynchronossPart |
private static class |
SynchronossPartHttpMessageReader.FluxSinkAdapterListener
Listen for parser output and adapt to
Flux<Sink<Part>> . |
private static class |
SynchronossPartHttpMessageReader.SynchronossFilePart |
private static class |
SynchronossPartHttpMessageReader.SynchronossFormFieldPart |
private static class |
SynchronossPartHttpMessageReader.SynchronossPartGenerator
Consume and feed input to the Synchronoss parser, then adapt parser
output events to
Flux<Sink<Part>> . |
Modifier and Type | Field and Description |
---|---|
private DataBufferFactory |
bufferFactory |
Constructor and Description |
---|
SynchronossPartHttpMessageReader() |
Modifier and Type | Method and Description |
---|---|
boolean |
canRead(ResolvableType elementType,
MediaType mediaType)
Whether the given object type is supported by this reader.
|
java.util.List<MediaType> |
getReadableMediaTypes()
Return the
MediaType 's that this reader supports. |
<any> |
read(ResolvableType elementType,
ReactiveHttpInputMessage message,
java.util.Map<java.lang.String,java.lang.Object> hints)
Read from the input message and encode to a stream of objects.
|
<any> |
readMono(ResolvableType elementType,
ReactiveHttpInputMessage message,
java.util.Map<java.lang.String,java.lang.Object> hints)
Read from the input message and encode to a single object.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
read, readMono
private final DataBufferFactory bufferFactory
public java.util.List<MediaType> getReadableMediaTypes()
HttpMessageReader
MediaType
's that this reader supports.getReadableMediaTypes
in interface HttpMessageReader<Part>
public boolean canRead(ResolvableType elementType, @Nullable MediaType mediaType)
HttpMessageReader
canRead
in interface HttpMessageReader<Part>
elementType
- the type of object to checkmediaType
- the media type for the read (possibly null
)true
if readable, false
otherwisepublic <any> read(ResolvableType elementType, ReactiveHttpInputMessage message, java.util.Map<java.lang.String,java.lang.Object> hints)
HttpMessageReader
read
in interface HttpMessageReader<Part>
elementType
- the type of objects in the stream which must have been
previously checked via HttpMessageReader.canRead(ResolvableType, MediaType)
message
- the message to read fromhints
- additional information about how to read and decode the inputpublic <any> readMono(ResolvableType elementType, ReactiveHttpInputMessage message, java.util.Map<java.lang.String,java.lang.Object> hints)
HttpMessageReader
readMono
in interface HttpMessageReader<Part>
elementType
- the type of objects in the stream which must have been
previously checked via HttpMessageReader.canRead(ResolvableType, MediaType)
message
- the message to read fromhints
- additional information about how to read and decode the input