Package io.micronaut.web.router
Interface ErrorRouteInfo<T,R>
- Type Parameters:
T
- The targetR
- The result
- All Superinterfaces:
AnnotationMetadataProvider
,AnnotationSource
,MethodBasedRouteInfo<T,
,R> RequestMatcher
,RouteInfo<R>
- All Known Implementing Classes:
DefaultErrorRouteInfo
Represents a
Route
that matches an exception.- Since:
- 1.0
- Author:
- Graeme Rocher
-
Field Summary
Fields inherited from interface io.micronaut.core.annotation.AnnotationSource
EMPTY
Fields inherited from interface io.micronaut.web.router.RouteInfo
DEFAULT_PRODUCES
-
Method Summary
Methods inherited from interface io.micronaut.core.annotation.AnnotationMetadataProvider
findAnnotation, findAnnotation, findDeclaredAnnotation, findDeclaredAnnotation, getAnnotationMetadata, getTargetAnnotationMetadata, isAnnotationPresent, isDeclaredAnnotationPresent, synthesize, synthesizeAll, synthesizeAnnotationsByType, synthesizeDeclared, synthesizeDeclared, synthesizeDeclaredAnnotationsByType
Methods inherited from interface io.micronaut.core.annotation.AnnotationSource
getAnnotation, getAnnotation, getDeclaredAnnotation, getDeclaredAnnotation, isAnnotationPresent, isDeclaredAnnotationPresent, synthesize, synthesizeDeclared
Methods inherited from interface io.micronaut.web.router.MethodBasedRouteInfo
getArgumentNames, getTargetMethod, resolveArgumentBinders
Methods inherited from interface io.micronaut.web.router.RequestMatcher
matching
Methods inherited from interface io.micronaut.web.router.RouteInfo
consumesAll, doesConsume, doesProduce, doesProduce, explicitlyConsumes, explicitlyProduces, findStatus, getBodyArgument, getBodyType, getConsumes, getDeclaringType, getExecutor, getFullRequestBodyType, getMessageBodyReader, getMessageBodyWriter, getProduces, getRequestBodyType, getResponseBodyType, getReturnType, isAsync, isAsyncOrReactive, isCompletable, isErrorRoute, isImperative, isPermitsRequestBody, isReactive, isResponseBodyJsonFormattable, isSingleResult, isSpecifiedSingle, isSuspended, isVoid, isWebSocketRoute, needsRequestBody, producesAll
-
Method Details
-
originatingType
Class<?> originatingType()- Returns:
- The type the exception originates from. Null if the error route is global.
-
exceptionType
- Returns:
- The type of exception
-
match
Match the given exception.- Parameters:
exception
- The exception to match- Returns:
- The route match
-
match
Match the given exception.- Parameters:
originatingClass
- The class where the error originates fromexception
- The exception to match- Returns:
- The route match
-