/** * Returns true if the path pattern matches the given path. */ default boolean matches(String path) { return getPattern().matches(path); }
@Override public boolean acceptsRedirectUri(String uri) { if(null == uri) { return false; } if(null != redirectUri && uri.startsWith(redirectUri)) { return true; } if(null != redirectUriPattern) { return redirectUriPattern.matches(Urls.removeQueryString(uri)); } return false; }
@Override public boolean acceptsLogoutUri(String uri) { if(null == uri) { return false; } if(null != logoutUri && uri.startsWith(logoutUri)) { return true; } if(null != logoutUriPattern) { return logoutUriPattern.matches(Urls.removeQueryString(uri)); } return false; }
@Override public boolean acceptsLogoutUri(String uri) { if(null == uri) { return false; } if(null != logoutUri && uri.startsWith(logoutUri)) { return true; } if(null != logoutUriPattern) { return logoutUriPattern.matches(Urls.removeQueryString(uri)); } return false; }
@Override public boolean acceptsRedirectUri(String uri) { if(null == uri) { return false; } if(null != redirectUri && uri.startsWith(redirectUri)) { return true; } if(null != redirectUriPattern) { //todo: hack ant path matcher String pattern = redirectUriPattern.pattern(); if(pattern.equals("*") || pattern.equals("**")) { return true; } return redirectUriPattern.matches(Urls.removeQueryString(uri)); } return false; }
/** * Returns true if the path pattern matches the request. */ default boolean matches(RequestBase request) { return getPattern().matches(request.getPath()); }