@Provider public class RestExceptionHandler extends Object implements javax.ws.rs.ext.ExceptionMapper<RestException>
RestException
s to error responses according to the status that is set in the exception.
Response content format: {"type" : "ExceptionType", "message" : "some exception message"}
Constructor and Description |
---|
RestExceptionHandler() |
Modifier and Type | Method and Description |
---|---|
javax.ws.rs.core.Response |
toResponse(RestException exception) |
public javax.ws.rs.core.Response toResponse(RestException exception)
toResponse
in interface javax.ws.rs.ext.ExceptionMapper<RestException>
Copyright © 2022. All rights reserved.