Class JacksonCborDecoder
java.lang.Object
org.springframework.http.codec.JacksonCodecSupport<tools.jackson.dataformat.cbor.CBORMapper>
org.springframework.http.codec.AbstractJacksonDecoder<tools.jackson.dataformat.cbor.CBORMapper>
org.springframework.http.codec.cbor.JacksonCborDecoder
- All Implemented Interfaces:
Decoder<Object>, HttpMessageDecoder<Object>
public class JacksonCborDecoder
extends AbstractJacksonDecoder<tools.jackson.dataformat.cbor.CBORMapper>
Decode bytes into CBOR and convert to Objects with Jackson 3.x.
Stream decoding is currently not supported.
- Since:
- 7.0
- Author:
- Sebastien Deleuze
- See Also:
-
Field Summary
Fields inherited from class JacksonCodecSupport
FILTER_PROVIDER_HINT, JSON_VIEW_HINT, logger, mapperRegistrations -
Constructor Summary
ConstructorsConstructorDescriptionConstruct a new instance with aCBORMappercustomized with theJacksonModules found byMapperBuilder.findModules(ClassLoader).JacksonCborDecoder(tools.jackson.dataformat.cbor.CBORMapper mapper) Construct a new instance with the providedCBORMapper.JacksonCborDecoder(tools.jackson.dataformat.cbor.CBORMapper.Builder builder) Construct a new instance with the providedCBORMapper.Buildercustomized with theJacksonModules found byMapperBuilder.findModules(ClassLoader).JacksonCborDecoder(tools.jackson.dataformat.cbor.CBORMapper.Builder builder, MimeType... mimeTypes) Construct a new instance with the providedCBORMapper.Buildercustomized with theJacksonModules found byMapperBuilder.findModules(ClassLoader), andMimeTypes.JacksonCborDecoder(tools.jackson.dataformat.cbor.CBORMapper mapper, MimeType... mimeTypes) Construct a new instance with the providedCBORMapperandMimeTypes. -
Method Summary
Modifier and TypeMethodDescriptionreactor.core.publisher.Flux<Object> decode(Publisher<DataBuffer> input, ResolvableType elementType, @Nullable MimeType mimeType, @Nullable Map<String, Object> hints) Decode aDataBufferinput stream into a Flux ofT.Methods inherited from class AbstractJacksonDecoder
canDecode, customizeReader, decode, decodeToMono, getAnnotation, getDecodableMimeTypes, getDecodableMimeTypes, getDecodeHints, getMaxInMemorySize, processInput, setMaxInMemorySizeMethods inherited from class JacksonCodecSupport
getHints, getJavaType, getMapper, getMapperRegistrations, getMappersForType, getMediaTypesForProblemDetail, getMimeTypes, getMimeTypes, getParameter, registerMappersForType, selectMapper, supportsMimeType
-
Constructor Details
-
JacksonCborDecoder
public JacksonCborDecoder()Construct a new instance with aCBORMappercustomized with theJacksonModules found byMapperBuilder.findModules(ClassLoader). -
JacksonCborDecoder
public JacksonCborDecoder(tools.jackson.dataformat.cbor.CBORMapper.Builder builder) Construct a new instance with the providedCBORMapper.Buildercustomized with theJacksonModules found byMapperBuilder.findModules(ClassLoader).- See Also:
-
JacksonCborDecoder
public JacksonCborDecoder(tools.jackson.dataformat.cbor.CBORMapper mapper) Construct a new instance with the providedCBORMapper.- See Also:
-
JacksonCborDecoder
-
JacksonCborDecoder
-
-
Method Details
-
decode
public reactor.core.publisher.Flux<Object> decode(Publisher<DataBuffer> input, ResolvableType elementType, @Nullable MimeType mimeType, @Nullable Map<String, Object> hints) Description copied from interface:DecoderDecode aDataBufferinput stream into a Flux ofT.- Specified by:
decodein interfaceDecoder<Object>- Overrides:
decodein classAbstractJacksonDecoder<tools.jackson.dataformat.cbor.CBORMapper>- Parameters:
input- theDataBufferinput stream to decodeelementType- the expected type of elements in the output stream; this type must have been previously passed to theDecoder.canDecode(ResolvableType, MimeType)method and it must have returnedtrue.mimeType- the MIME type associated with the input stream (optional)hints- additional information about how to do decode- Returns:
- the output stream with decoded elements
-