RequestMappingInfoHandlerMapping.java (spring-framework-5.3.23) | : | RequestMappingInfoHandlerMapping.java (spring-framework-5.3.24) | ||
---|---|---|---|---|
skipping to change at line 143 | skipping to change at line 143 | |||
"Expected bestPattern: " + bestPattern + " to match lookupPath " + lookupPath); | "Expected bestPattern: " + bestPattern + " to match lookupPath " + lookupPath); | |||
uriVariables = result.getUriVariables(); | uriVariables = result.getUriVariables(); | |||
matrixVariables = result.getMatrixVariables(); | matrixVariables = result.getMatrixVariables(); | |||
} | } | |||
exchange.getAttributes().put(BEST_MATCHING_HANDLER_ATTRIBUTE, han dlerMethod); | exchange.getAttributes().put(BEST_MATCHING_HANDLER_ATTRIBUTE, han dlerMethod); | |||
exchange.getAttributes().put(BEST_MATCHING_PATTERN_ATTRIBUTE, bes tPattern); | exchange.getAttributes().put(BEST_MATCHING_PATTERN_ATTRIBUTE, bes tPattern); | |||
exchange.getAttributes().put(URI_TEMPLATE_VARIABLES_ATTRIBUTE, ur iVariables); | exchange.getAttributes().put(URI_TEMPLATE_VARIABLES_ATTRIBUTE, ur iVariables); | |||
exchange.getAttributes().put(MATRIX_VARIABLES_ATTRIBUTE, matrixVa riables); | exchange.getAttributes().put(MATRIX_VARIABLES_ATTRIBUTE, matrixVa riables); | |||
if (!info.getProducesCondition().getProducibleMediaTypes().isEmpt | ProducesRequestCondition producesCondition = info.getProducesCond | |||
y()) { | ition(); | |||
Set<MediaType> mediaTypes = info.getProducesCondition().g | if (!producesCondition.isEmpty()) { | |||
etProducibleMediaTypes(); | Set<MediaType> mediaTypes = producesCondition.getProducib | |||
exchange.getAttributes().put(PRODUCIBLE_MEDIA_TYPES_ATTRI | leMediaTypes(); | |||
BUTE, mediaTypes); | if (!mediaTypes.isEmpty()) { | |||
exchange.getAttributes().put(PRODUCIBLE_MEDIA_TYP | ||||
ES_ATTRIBUTE, mediaTypes); | ||||
} | ||||
} | } | |||
} | } | |||
/** | /** | |||
* Iterate all RequestMappingInfos once again, look if any match by URL a t | * Iterate all RequestMappingInfos once again, look if any match by URL a t | |||
* least and raise exceptions accordingly. | * least and raise exceptions accordingly. | |||
* @throws MethodNotAllowedException for matches by URL but not by HTTP m ethod | * @throws MethodNotAllowedException for matches by URL but not by HTTP m ethod | |||
* @throws UnsupportedMediaTypeStatusException if there are matches by UR L | * @throws UnsupportedMediaTypeStatusException if there are matches by UR L | |||
* and HTTP method but not by consumable media types | * and HTTP method but not by consumable media types | |||
* @throws NotAcceptableStatusException if there are matches by URL and H TTP | * @throws NotAcceptableStatusException if there are matches by URL and H TTP | |||
End of changes. 1 change blocks. | ||||
6 lines changed or deleted | 9 lines changed or added |