Package org.springframework.http.codec
Interface HttpMessageDecoder<T>
- Type Parameters:
T
- the type of elements in the output stream
- All Superinterfaces:
Decoder<T>
- All Known Implementing Classes:
AbstractJackson2Decoder
,Jackson2CborDecoder
,Jackson2JsonDecoder
,Jackson2SmileDecoder
Extension of
Decoder
exposing extra methods relevant in the context
of HTTP request or response body decoding.- Since:
- 5.0
- Author:
- Rossen Stoyanchev
-
Method Summary
Modifier and TypeMethodDescriptiongetDecodeHints
(ResolvableType actualType, ResolvableType elementType, ServerHttpRequest request, ServerHttpResponse response) Get decoding hints based on the server request or annotations on the target controller method parameter.Methods inherited from interface org.springframework.core.codec.Decoder
canDecode, decode, decode, decodeToMono, getDecodableMimeTypes, getDecodableMimeTypes
-
Method Details
-
getDecodeHints
Map<String,Object> getDecodeHints(ResolvableType actualType, ResolvableType elementType, ServerHttpRequest request, ServerHttpResponse response) Get decoding hints based on the server request or annotations on the target controller method parameter.- Parameters:
actualType
- the actual target type to decode to, possibly a reactive wrapper and sourced fromMethodParameter
, i.e. providing access to method parameter annotationselementType
- the element type withinFlux/Mono
that we're trying to decode torequest
- the current requestresponse
- the current response- Returns:
- a Map with hints, possibly empty
-