C
- The object that is returned or Chained after creating the RequestMatcherpublic abstract class AbstractRequestMatcherRegistry<C> extends Object
RequestMatcher
's. For example, it might allow for
specifying which RequestMatcher
require a certain level of authorization.Constructor and Description |
---|
AbstractRequestMatcherRegistry() |
Modifier and Type | Method and Description |
---|---|
C |
antMatchers(HttpMethod method)
Maps a
List of
AntPathRequestMatcher
instances. |
C |
antMatchers(HttpMethod method,
String... antPatterns)
Maps a
List of
AntPathRequestMatcher
instances. |
C |
antMatchers(String... antPatterns)
|
C |
anyRequest()
Maps any request.
|
protected abstract C |
chainRequestMatchers(List<RequestMatcher> requestMatchers)
Subclasses should implement this method for returning the object that is chained to
the creation of the
RequestMatcher instances. |
C |
regexMatchers(HttpMethod method,
String... regexPatterns)
Maps a
List of
RegexRequestMatcher
instances. |
C |
regexMatchers(String... regexPatterns)
|
C |
requestMatchers(RequestMatcher... requestMatchers)
Associates a list of
RequestMatcher instances with the
AbstractConfigAttributeRequestMatcherRegistry |
public C anyRequest()
RequestMatcher
public C antMatchers(HttpMethod method)
List
of
AntPathRequestMatcher
instances.method
- the HttpMethod
to use for any
HttpMethod
.RequestMatcher
public C antMatchers(HttpMethod method, String... antPatterns)
List
of
AntPathRequestMatcher
instances.method
- the HttpMethod
to use or null
for any
HttpMethod
.antPatterns
- the ant patterns to create. If null
or empty, then matches on nothing.
AntPathRequestMatcher
fromRequestMatcher
public C antMatchers(String... antPatterns)
antPatterns
- the ant patterns to create
AntPathRequestMatcher
fromRequestMatcher
public C regexMatchers(HttpMethod method, String... regexPatterns)
List
of
RegexRequestMatcher
instances.method
- the HttpMethod
to use or null
for any
HttpMethod
.regexPatterns
- the regular expressions to create
RegexRequestMatcher
fromRequestMatcher
public C regexMatchers(String... regexPatterns)
regexPatterns
- the regular expressions to create
RegexRequestMatcher
fromRequestMatcher
public C requestMatchers(RequestMatcher... requestMatchers)
RequestMatcher
instances with the
AbstractConfigAttributeRequestMatcherRegistry
requestMatchers
- the RequestMatcher
instancesRequestMatcher
protected abstract C chainRequestMatchers(List<RequestMatcher> requestMatchers)
RequestMatcher
instances.requestMatchers
- the RequestMatcher
instances that were createdRequestMatcher