@Target(value=TYPE) @Retention(value=RUNTIME) @Documented @Import(value=ErrorHandlerCreationConfigurer.class) public @interface EnableErrorHandler
ErrorHandler,
ExceptionHandler,
ExceptionHandlerObject| Modifier and Type | Optional Element and Description |
|---|---|
Class<?>[] |
basePackageClasses
Type-safe alternative to
basePackages()
for specifying the packages to scan for annotated ExceptionHandler. |
String[] |
basePackages
Base packages to scan for annotated
ExceptionHandler. |
String[] |
value
Alias for the
basePackages() attribute. |
@AliasFor(value="basePackages") public abstract String[] value
basePackages() attribute. Allows for more concise annotation declarations e.g.:
@EnableErrorHandler("org.my.pkg") instead of @EnableErrorHandler(basePackages="org.my.pkg").basePackages().@AliasFor(value="value") public abstract String[] basePackages
ExceptionHandler.
value() is an alias for (and mutually exclusive with) this
attribute. Use basePackageClasses() for a type-safe alternative to String-based package names.public abstract Class<?>[] basePackageClasses
basePackages()
for specifying the packages to scan for annotated ExceptionHandler.
The package of each class specified will be scanned.
Consider creating a special no-op marker class or interface in
each package that serves no purpose other than being referenced by this attribute.Copyright © 2018. All rights reserved.