public final class ExceptionResponse extends Object
Wraps all WebExceptions thrown by controlled workflow. If unexpected
Exceptions occur a general InternalServerException should be wrapped
so that all exceptions interrupting the expected workflow can be serialized
and returned to the requesting user/service.
To ensure all exceptions are handled and communicated to the user all Web
bindings shall inherit from BaseController which is
configured by default to serve as a central ExceptionHandler.
| Modifier and Type | Method and Description |
|---|---|
static ExceptionResponse |
createExceptionResponse(WebException e,
org.springframework.http.HttpStatus statusCode) |
String |
getDeveloperMessage() |
String[] |
getHints() |
String |
getReason() |
int |
getStatusCode() |
String |
getUserMessage() |
public int getStatusCode()
public String getReason()
public String getUserMessage()
public String getDeveloperMessage()
public String[] getHints()
public static ExceptionResponse createExceptionResponse(WebException e, org.springframework.http.HttpStatus statusCode)
Copyright © 2013–2019 52North Initiative for Geospatial Open Source Software GmbH. All rights reserved.