Class JsonParseExceptionMapper

  • All Implemented Interfaces:
    javax.ws.rs.ext.ExceptionMapper<com.fasterxml.jackson.core.JsonParseException>, ExceptionDebugLogging

    @Provider
    public class JsonParseExceptionMapper
    extends Object
    implements javax.ws.rs.ext.ExceptionMapper<com.fasterxml.jackson.core.JsonParseException>, ExceptionDebugLogging
    If an injected JSON resource fails to parse, return an HTTP 400 Bad Request.
    Since:
    2014-05-21
    Author:
    Esme Cowles
    • Method Detail

      • toResponse

        public javax.ws.rs.core.Response toResponse​(com.fasterxml.jackson.core.JsonParseException e)
        Specified by:
        toResponse in interface javax.ws.rs.ext.ExceptionMapper<com.fasterxml.jackson.core.JsonParseException>