From b542b5277500cd6261a6126bbd73fec2c9250e5b Mon Sep 17 00:00:00 2001 From: Rossen Stoyanchev Date: Thu, 25 Jun 2015 09:41:59 -0400 Subject: [PATCH] Update Javadoc on AntPathMatcher --- .../main/java/org/springframework/util/AntPathMatcher.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/spring-core/src/main/java/org/springframework/util/AntPathMatcher.java b/spring-core/src/main/java/org/springframework/util/AntPathMatcher.java index 4f9fdfc924..3132b1c46e 100644 --- a/spring-core/src/main/java/org/springframework/util/AntPathMatcher.java +++ b/spring-core/src/main/java/org/springframework/util/AntPathMatcher.java @@ -52,6 +52,11 @@ import java.util.regex.Pattern; * {@code org/springframework/testing/servlet/bla.jsp} and {@code org/servlet/bla.jsp} * * + *

Note: a pattern and a path must both be absolute or must + * both be relative in order for the two to match. Therefore it is recommended + * that users of this implementation to sanitize patterns in order to prefix + * them with "/" as it makes sense in the context in which they're used. + * * @author Alef Arendsen * @author Juergen Hoeller * @author Rob Harrop