java

位置:IT落伍者 >> java >> 浏览文章

Spring3 url匹配规则


发布日期:2022年01月29日
 
Spring3 url匹配规则

Spring url匹配规则

Wildcard Description

? 匹配任何单字符

* 匹配或者任意数量的字符

** 匹配或者更多的目录

举例

Path Description

/app/*x 匹配(Matches)所有在app路径下的x文件

/app/p?ttern 匹配(Matches) /app/pattern 和 /app/pXttern但是不包括/app/pttern

/**/example 匹配(Matches) /app/example /app/foo/example 和 /example

/app/**/dir/file 匹配(Matches) /app/dir/filejsp /app/foo/dir/l/app/foo/bar/dir/filepdf 和 /app/dir/filejava

/**/*jsp 匹配(Matches)任何的jsp 文件

上一篇:Hibernate基础全面介绍

下一篇:用Struts建立MVC应用的介绍