Class HateoasErrorResponseProcessor
java.lang.Object
io.micronaut.http.server.exceptions.response.HateoasErrorResponseProcessor
- All Implemented Interfaces:
ErrorResponseProcessor<JsonError>
@Deprecated(forRemoval=true)
public class HateoasErrorResponseProcessor
extends Object
implements ErrorResponseProcessor<JsonError>
Deprecated, for removal: This API element is subject to removal in a future version.
Creates Hateoas JSON error responses.
- Since:
- 2.4.0
- Author:
- James Kleeh
-
Constructor Summary
ConstructorDescriptionHateoasErrorResponseProcessor
(JsonConfiguration jacksonConfiguration) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Modifier and TypeMethodDescriptionprocessResponse
(@NonNull ErrorContext errorContext, @NonNull MutableHttpResponse<?> response) Deprecated, for removal: This API element is subject to removal in a future version.Modifies the http response representing the error.
-
Constructor Details
-
HateoasErrorResponseProcessor
Deprecated, for removal: This API element is subject to removal in a future version.
-
-
Method Details
-
processResponse
@NonNull public @NonNull MutableHttpResponse<JsonError> processResponse(@NonNull @NonNull ErrorContext errorContext, @NonNull @NonNull MutableHttpResponse<?> response) Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:ErrorResponseProcessor
Modifies the http response representing the error. Callers of this method should return the response that was passed in baseResponse parameter, however that isn't required. Error response processors should not set the body or content type if the request method is HEAD.- Specified by:
processResponse
in interfaceErrorResponseProcessor<JsonError>
- Parameters:
errorContext
- The error contextresponse
- The base response to retrieve information or mutate- Returns:
- An error response
-
DefaultErrorResponseProcessor
instead