Annotation Interface Interceptor
A custom
Component annotation for HandlerInterceptor and the interceptor would be auto-detects by a
custom a WebMvcConfigurer.
@Interceptor(includes="/**")
public class MyHandlerInterceptor implements HandlerInterceptor{
...
}
- 从以下版本开始:
- 1.0.0
- 版本:
- 1.0.0
- 作者:
- ilikly
- 另请参阅:
-
InterceptorRegistrationHandlerInterceptorWebMvcConfigurer.addInterceptors(InterceptorRegistry)
-
可选元素概要
可选元素
-
元素详细资料
-
value
- 默认值:
- ""
-
includes
String[] includesreturn the path patterns.- 返回:
- the path patterns.
- 另请参阅:
-
InterceptorRegistration.addPathPatterns(String...)InterceptorRegistration.addPathPatterns(List)
- 默认值:
- {}
-
excludes
String[] excludesreturn exclude path patterns.- 返回:
- exclude path patterns.
- 另请参阅:
-
InterceptorRegistration.excludePathPatterns(String...)InterceptorRegistration.excludePathPatterns(List)
- 默认值:
- {}
-