RequestMatcher使用。
1.设置匹配规则
private RequestMatcher matcherHtml = new AntPathRequestMatcher("/**", "GET");
2.把ServletRequest转化成HttpServletRequest,强转即可
3.调用matches方法进行匹配
matcherBbsHtml.matches(request) public interface RequestMatcher { boolean matches(HttpServletRequest request); }