Class WebApplicationExceptionMapper
java.lang.Object
io.goobi.viewer.api.rest.exceptions.WebApplicationExceptionMapper
- All Implemented Interfaces:
javax.ws.rs.ext.ExceptionMapper<javax.ws.rs.WebApplicationException>
@Provider
public class WebApplicationExceptionMapper
extends Object
implements javax.ws.rs.ext.ExceptionMapper<javax.ws.rs.WebApplicationException>
Catches general exceptions encountered during rest-api calls and creates an error response.
- Author:
- Florian Alpers
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetRequestHeaders.javax.ws.rs.core.Response
toResponse
(javax.ws.rs.WebApplicationException eParent)
-
Constructor Details
-
WebApplicationExceptionMapper
public WebApplicationExceptionMapper()
-
-
Method Details
-
toResponse
public javax.ws.rs.core.Response toResponse(javax.ws.rs.WebApplicationException eParent) - Specified by:
toResponse
in interfacejavax.ws.rs.ext.ExceptionMapper<javax.ws.rs.WebApplicationException>
-
getRequestHeaders
getRequestHeaders.
- Returns:
- a
String
object.
-