protected static class FilteringOutlinePopup.StringMatcher
extends java.lang.Object
implements java.util.function.Predicate<java.lang.String>
Constructor and Description |
---|
StringMatcher(java.lang.String pattern,
boolean ignoreCase)
Creates a new string matcher based on the given pattern.
|
Modifier and Type | Method and Description |
---|---|
boolean |
test(java.lang.String text) |
protected java.lang.String |
translatePattern(java.lang.String pattern)
Translates the given pattern into a regular expression.
|
public StringMatcher(java.lang.String pattern, boolean ignoreCase)
pattern
- the pattern string (not null
)ignoreCase
- whether case-insensitive matching is enabledpublic final boolean test(java.lang.String text)
test
in interface java.util.function.Predicate<java.lang.String>
protected java.lang.String translatePattern(java.lang.String pattern)
This implementation always returns a regular expression that starts with '^'.
pattern
- the pattern string (not null
)null
)Copyright (c) 2014, 2020 1C-Soft LLC and others. Made available under the Eclipse Public License 2.0