public abstract class PrefixMatcher
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static PrefixMatcher |
ALWAYS_TRUE |
protected java.lang.String |
myPrefix |
Modifier | Constructor and Description |
---|---|
protected |
PrefixMatcher(java.lang.String prefix) |
Modifier and Type | Method and Description |
---|---|
abstract PrefixMatcher |
cloneWithPrefix(java.lang.String prefix) |
java.lang.String |
getPrefix() |
boolean |
isStartMatch(LookupElement element) |
boolean |
isStartMatch(java.lang.String name) |
int |
matchingDegree(java.lang.String string) |
boolean |
prefixMatches(LookupElement element) |
abstract boolean |
prefixMatches(java.lang.String name) |
java.util.LinkedHashSet<java.lang.String> |
sortMatching(java.util.Collection<java.lang.String> _names)
Filters _names for strings that match given matcher and sorts them.
|
public static final PrefixMatcher ALWAYS_TRUE
protected final java.lang.String myPrefix
public boolean prefixMatches(LookupElement element)
public boolean isStartMatch(LookupElement element)
public boolean isStartMatch(java.lang.String name)
public abstract boolean prefixMatches(java.lang.String name)
public final java.lang.String getPrefix()
public abstract PrefixMatcher cloneWithPrefix(java.lang.String prefix)
public int matchingDegree(java.lang.String string)
public java.util.LinkedHashSet<java.lang.String> sortMatching(java.util.Collection<java.lang.String> _names)