Package org.bremersee.exception
Class RestApiExceptionParserImpl
- java.lang.Object
-
- org.bremersee.exception.RestApiExceptionParserImpl
-
- All Implemented Interfaces:
org.bremersee.exception.ExceptionParser<org.bremersee.exception.model.RestApiException>
,RestApiExceptionParser
public class RestApiExceptionParserImpl extends Object implements RestApiExceptionParser
The default implementation of a http response parser that creates aRestApiException
.- Author:
- Christian Bremer
-
-
Constructor Summary
Constructors Constructor Description RestApiExceptionParserImpl()
RestApiExceptionParserImpl(com.fasterxml.jackson.databind.ObjectMapper objectMapper, com.fasterxml.jackson.dataformat.xml.XmlMapper xmlMapper)
RestApiExceptionParserImpl(org.springframework.http.converter.json.Jackson2ObjectMapperBuilder objectMapperBuilder)
Instantiates a new rest api exception parser.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.bremersee.exception.model.RestApiException
parseException(String response, Map<String,? extends Collection<String>> headers)
-
-
-
Constructor Detail
-
RestApiExceptionParserImpl
public RestApiExceptionParserImpl()
-
RestApiExceptionParserImpl
public RestApiExceptionParserImpl(org.springframework.http.converter.json.Jackson2ObjectMapperBuilder objectMapperBuilder)
Instantiates a new rest api exception parser.- Parameters:
objectMapperBuilder
- the object mapper builder
-
RestApiExceptionParserImpl
public RestApiExceptionParserImpl(com.fasterxml.jackson.databind.ObjectMapper objectMapper, com.fasterxml.jackson.dataformat.xml.XmlMapper xmlMapper)
-
-
Method Detail
-
parseException
public org.bremersee.exception.model.RestApiException parseException(@Nullable String response, @Nullable Map<String,? extends Collection<String>> headers)
- Specified by:
parseException
in interfaceorg.bremersee.exception.ExceptionParser<org.bremersee.exception.model.RestApiException>
-
-