E
- the endpoint typepublic class IncludeExcludeEndpointFilter<E extends ExposableEndpoint<?>> extends Object implements EndpointFilter<E>
Modifier and Type | Class and Description |
---|---|
static class |
IncludeExcludeEndpointFilter.DefaultIncludes
Default include patterns that can be used.
|
Constructor and Description |
---|
IncludeExcludeEndpointFilter(Class<E> endpointType,
Collection<String> include,
Collection<String> exclude,
IncludeExcludeEndpointFilter.DefaultIncludes defaultIncludes)
Create a new
IncludeExcludeEndpointFilter with specific include/exclude
rules. |
IncludeExcludeEndpointFilter(Class<E> endpointType,
Collection<String> include,
Collection<String> exclude,
String... defaultIncludes)
Create a new
IncludeExcludeEndpointFilter with specific include/exclude
rules. |
IncludeExcludeEndpointFilter(Class<E> endpointType,
Environment environment,
String prefix,
IncludeExcludeEndpointFilter.DefaultIncludes defaultIncludes)
Create a new
IncludeExcludeEndpointFilter with include/exclude rules bound
from the Environment . |
IncludeExcludeEndpointFilter(Class<E> endpointType,
Environment environment,
String prefix,
String... defaultIncludes)
Create a new
IncludeExcludeEndpointFilter with include/exclude rules bound
from the Environment . |
Modifier and Type | Method and Description |
---|---|
boolean |
match(E endpoint)
Return
true if the filter matches. |
protected boolean |
match(EndpointId endpointId)
Return
true if the filter matches. |
public IncludeExcludeEndpointFilter(Class<E> endpointType, Environment environment, String prefix, String... defaultIncludes)
IncludeExcludeEndpointFilter
with include/exclude rules bound
from the Environment
.endpointType
- the endpoint type that should be considered (other types always
match)environment
- the environment containing the propertiesprefix
- the property prefix to binddefaultIncludes
- the default includes
to use when none are specified.public IncludeExcludeEndpointFilter(Class<E> endpointType, Environment environment, String prefix, IncludeExcludeEndpointFilter.DefaultIncludes defaultIncludes)
IncludeExcludeEndpointFilter
with include/exclude rules bound
from the Environment
.endpointType
- the endpoint type that should be considered (other types always
match)environment
- the environment containing the propertiesprefix
- the property prefix to binddefaultIncludes
- the default includes
to use when none are specified.public IncludeExcludeEndpointFilter(Class<E> endpointType, Collection<String> include, Collection<String> exclude, String... defaultIncludes)
IncludeExcludeEndpointFilter
with specific include/exclude
rules.endpointType
- the endpoint type that should be considered (other types always
match)include
- the include patternsexclude
- the exclude patternsdefaultIncludes
- the default includes
to use when none are specified.public IncludeExcludeEndpointFilter(Class<E> endpointType, Collection<String> include, Collection<String> exclude, IncludeExcludeEndpointFilter.DefaultIncludes defaultIncludes)
IncludeExcludeEndpointFilter
with specific include/exclude
rules.endpointType
- the endpoint type that should be considered (other types always
match)include
- the include patternsexclude
- the exclude patternsdefaultIncludes
- the default includes
to use when none are specified.public boolean match(E endpoint)
EndpointFilter
true
if the filter matches.match
in interface EndpointFilter<E extends ExposableEndpoint<?>>
endpoint
- the endpoint to checktrue
if the filter matchesprotected final boolean match(EndpointId endpointId)
true
if the filter matches.endpointId
- the endpoint ID to checktrue
if the filter matches