public abstract class AbstractExceptionHandlerMethodResolver extends Object
ExceptionDepthComparator
and the top match is returned.Modifier | Constructor and Description |
---|---|
protected |
AbstractExceptionHandlerMethodResolver(Map<Class<? extends Throwable>,Method> mappedMethods)
Protected constructor accepting exception-to-method mappings.
|
Modifier and Type | Method and Description |
---|---|
protected static List<Class<? extends Throwable>> |
getExceptionsFromMethodSignature(Method method)
Extract the exceptions this method handles.This implementation looks for
sub-classes of Throwable in the method signature.
|
boolean |
hasExceptionMappings()
Whether the contained type has any exception mappings.
|
Method |
resolveMethod(Exception exception)
Find a method to handle the given exception.
|
protected static List<Class<? extends Throwable>> getExceptionsFromMethodSignature(Method method)
public boolean hasExceptionMappings()
public Method resolveMethod(Exception exception)
ExceptionDepthComparator
if more than one match is found.exception
- the exceptionnull