Interface ExceptionHandlerFunction
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
An interface for exception handler.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T> T
Throws aFallthroughException
in order to try to handle theThrowable
by the next handler.handleException
(ServiceRequestContext ctx, HttpRequest req, Throwable cause) Returns anHttpResponse
which would be sent back to the client who sent thereq
.
-
Method Details
-
handleException
@CheckReturnValue HttpResponse handleException(ServiceRequestContext ctx, HttpRequest req, Throwable cause) Returns anHttpResponse
which would be sent back to the client who sent thereq
. Callsfallthrough()
if this handler cannot handle thecause
. -
fallthrough
static <T> T fallthrough()Throws aFallthroughException
in order to try to handle theThrowable
by the next handler.
-