1 | protected static boolean matchPatternStart(String pattern, String str) {↵ | | 1 | protected static boolean matchPath(String pattern, String str) {↵
|
2 | return SelectorUtils.matchPatternStart(pattern, str);↵ | | 2 | return SelectorUtils.matchPath(pattern, str);↵
|
3 | }↵ | | 3 | }↵
|
|
4 | /**↵ | | 4 | /**↵
|
5 | * Test whether or not a given path matches the start of a given↵ | | 5 | * Test whether or not a given path matches ↵
|
6 | * pattern up to the first "**".↵ | | |
|
7 | * <p>↵ | | |
|
8 | * This is not a general purpose test and should only be used if you↵ | | |
|
9 | * can live with false positives. For example, <code>pattern=**\a</code>↵ | | |
|
10 | * and <code>str=b</code> will yield <code>true</code>.↵ | | 6 | a given pattern.↵
|
11 | *↵ | | 7 | *↵
|
12 | * @param pattern The pattern to match against. Must not be↵ | | 8 | * @param pattern The pattern to match against. Must not be↵
|
13 | * <code>null</code>.↵ | | 9 | * <code>null</code>.↵
|
14 | * @param str The path to match, as a String. Must not be↵ | | 10 | * @param str The path to match, as a String. Must not be↵
|
15 | * <code>null</code>.↵ | | 11 | * <code>null</code>.↵
|
16 | * @param isCaseSensitive Whether or not matching should be performed↵ | | 12 | * @param isCaseSensitive Whether or not matching should be performed↵
|
17 | * case sensitively.↵ | | 13 | * case sensitively.↵
|
18 | *↵ | | 14 | *↵
|
19 | * @return whether or not a given path matches the start of a given↵ | | 15 | * @return <code>true</code> if the pattern matches ↵
|
20 | * pattern up to the first "**"↵ | | 16 | against the string,↵
|
21 | .↵ | | 17 | * or <code>false</code> otherwise.↵
|
22 | */↵ | | 18 | */↵
|
23 | protected static boolean matchPatternStart(String pattern, String str,↵ | | 19 | protected static boolean matchPath(String pattern, String str,↵
|
24 | boolean isCaseSensitive) {↵ | | 20 | boolean isCaseSensitive) {↵
|
25 | return SelectorUtils.matchPatternStart(pattern, str, isCaseSensitive); | | 21 | return SelectorUtils.matchPath(pattern, str, isCaseSensitive);
|