public static class ErrorHandlers.OAuthErrorHandler extends ErrorHandler
Constructor and Description |
---|
OAuthErrorHandler() |
Modifier and Type | Method and Description |
---|---|
void |
accept(ErrorResponse errorResponse) |
ErrorResponse |
parseResponse(int code,
java.lang.String json,
com.fasterxml.jackson.databind.ObjectMapper mapper)
Parses the response and creates an ErrorResponse object based on the response code and the JSON
data using the provided ObjectMapper.
|
public ErrorResponse parseResponse(int code, java.lang.String json, com.fasterxml.jackson.databind.ObjectMapper mapper)
ErrorHandler
code
- The response code indicating the error status.json
- The JSON data representing the error response.mapper
- The ObjectMapper used to deserialize the JSON data.public void accept(ErrorResponse errorResponse)
accept
in interface java.util.function.Consumer<ErrorResponse>