class IncludeClassNameFilter extends AbstractClassNameFilter
ClassNameFilter
that matches fully qualified class names against
patterns in the form of regular expressions.
If the fully qualified name of a class matches against at least one pattern, the class will be included.
patternDescription, patterns
STANDARD_INCLUDE_PATTERN
Constructor and Description |
---|
IncludeClassNameFilter(java.lang.String... patterns) |
Modifier and Type | Method and Description |
---|---|
FilterResult |
apply(java.lang.String className)
Apply this filter to the supplied object.
|
private java.lang.String |
formatExclusionReason(java.lang.String className) |
private java.lang.String |
formatInclusionReason(java.lang.String className,
java.util.regex.Pattern pattern) |
java.util.function.Predicate<java.lang.String> |
toPredicate()
Return a
Predicate that returns true if this filter
includes the object supplied to the predicate's
test method. |
java.lang.String |
toString() |
findMatchingPattern
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
excludeClassNamePatterns, includeClassNamePatterns
adaptFilter, composeFilters, composeFilters
public FilterResult apply(java.lang.String className)
Filter
private java.lang.String formatInclusionReason(java.lang.String className, java.util.regex.Pattern pattern)
private java.lang.String formatExclusionReason(java.lang.String className)
public java.util.function.Predicate<java.lang.String> toPredicate()
Filter
Predicate
that returns true
if this filter
includes the object supplied to the predicate's
test
method.toPredicate
in interface Filter<java.lang.String>
toPredicate
in class AbstractClassNameFilter
public java.lang.String toString()
toString
in class java.lang.Object