spring通配符工具类

来源:互联网 发布:剑灵大地召唤卡刀数据 编辑:程序博客网 时间:2024/05/17 07:10

接口

org.springframework.util.PathMatcher

实现

org.springframework.util.AntPathMatcher


public static void main(String[] args) {String path = "/admin/1/2";String pattern = "/admin/**";PathMatcher pm = new AntPathMatcher();boolean matchStart = pm.matchStart( pattern, path );System.out.println( matchStart );}



0 0
原创粉丝点击