@CompileStatic class UrlMappingMatcher extends java.lang.Object implements Matcher
Used to match UrlMappingInfo instance by Interceptor instances
URI patterns are matched against the path passed to doesMatch(String, UrlMappingInfo, String, String)
as-is. Interceptor.doesMatch passes the decoded,
application-relative path that URL mappings route on, so this class must not decode or remove matrix parameters
again: that would match a different path than the one dispatched (/health%3Bx is dispatched as
/health;x, not as /health).
| Modifiers | Name | Description |
|---|---|---|
static class |
UrlMappingMatcher.ClosureExclude |
|
static interface |
UrlMappingMatcher.Exclude |
|
static class |
UrlMappingMatcher.MapExclude |
| Modifiers | Name | Description |
|---|---|---|
static java.util.regex.Pattern |
WILD_CARD_PATTERN |
|
protected java.util.regex.Pattern |
actionRegex |
|
protected java.util.regex.Pattern |
controllerRegex |
|
protected java.util.List<Exclude> |
excludes |
|
protected Interceptor |
interceptor |
|
protected boolean |
matchAll |
|
protected java.util.regex.Pattern |
methodRegex |
|
protected java.util.regex.Pattern |
namespaceRegex |
|
protected AntPathMatcher |
pathMatcher |
|
protected java.util.List<java.lang.String> |
uriExcludePatterns |
|
protected java.util.List<java.lang.String> |
uriPatterns |
| Constructor and description |
|---|
UrlMappingMatcher(Interceptor interceptor) |
| Type Params | Return Type | Name and description |
|---|---|---|
|
boolean |
doesMatch(java.lang.String uri, UrlMappingInfo info) |
|
boolean |
doesMatch(java.lang.String uri, UrlMappingInfo info, java.lang.String method) |
|
boolean |
doesMatch(java.lang.String uri, UrlMappingInfo info, java.lang.String method, java.lang.String contextPath) |
|
protected boolean |
doesMatchInternal(UrlMappingInfo info, java.lang.String method) |
|
Matcher |
except(java.util.Map arguments) |
|
Matcher |
excludes(java.util.Map arguments) |
|
Matcher |
excludes(Closure<java.lang.Boolean> condition) |
|
protected int |
hashCode(UrlMappingInfo info) |
|
boolean |
isExclude() |
|
protected boolean |
isExcluded(java.lang.String uri, UrlMappingInfo info) |
|
protected boolean |
isExcluded(java.lang.String uri, UrlMappingInfo info, java.lang.String contextPath) |
|
Matcher |
matchAll() |
|
Matcher |
matches(java.util.Map arguments) |
| Methods inherited from class | Name |
|---|---|
class java.lang.Object |
java.lang.Object#equals(java.lang.Object), java.lang.Object#getClass(), java.lang.Object#hashCode(), java.lang.Object#notify(), java.lang.Object#notifyAll(), java.lang.Object#toString(), java.lang.Object#wait(), java.lang.Object#wait(long), java.lang.Object#wait(long, int) |