public enum PreBuiltTokenizers extends java.lang.Enum<PreBuiltTokenizers>
Enum Constant and Description |
---|
CLASSIC |
EDGE_NGRAM |
KEYWORD |
LETTER |
LOWERCASE |
NGRAM |
PATH_HIERARCHY |
PATTERN |
STANDARD |
THAI |
UAX_URL_EMAIL |
WHITESPACE |
Modifier and Type | Field and Description |
---|---|
protected PreBuiltCacheFactory.PreBuiltCache<TokenizerFactory> |
cache |
Modifier and Type | Method and Description |
---|---|
protected abstract org.apache.lucene.analysis.Tokenizer |
create(Version version) |
protected TokenFilterFactory |
getMultiTermComponent(Version version) |
static PreBuiltTokenizers |
getOrDefault(java.lang.String name,
PreBuiltTokenizers defaultTokenizer)
Get a pre built Tokenizer by its name or fallback to the default one
|
TokenizerFactory |
getTokenizerFactory(Version version) |
static PreBuiltTokenizers |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static PreBuiltTokenizers[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final PreBuiltTokenizers STANDARD
public static final PreBuiltTokenizers CLASSIC
public static final PreBuiltTokenizers UAX_URL_EMAIL
public static final PreBuiltTokenizers PATH_HIERARCHY
public static final PreBuiltTokenizers KEYWORD
public static final PreBuiltTokenizers LETTER
public static final PreBuiltTokenizers LOWERCASE
public static final PreBuiltTokenizers WHITESPACE
public static final PreBuiltTokenizers NGRAM
public static final PreBuiltTokenizers EDGE_NGRAM
public static final PreBuiltTokenizers PATTERN
public static final PreBuiltTokenizers THAI
protected final PreBuiltCacheFactory.PreBuiltCache<TokenizerFactory> cache
public static PreBuiltTokenizers[] values()
for (PreBuiltTokenizers c : PreBuiltTokenizers.values()) System.out.println(c);
public static PreBuiltTokenizers valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is nullprotected abstract org.apache.lucene.analysis.Tokenizer create(Version version)
protected TokenFilterFactory getMultiTermComponent(Version version)
public TokenizerFactory getTokenizerFactory(Version version)
public static PreBuiltTokenizers getOrDefault(java.lang.String name, PreBuiltTokenizers defaultTokenizer)
name
- Tokenizer namedefaultTokenizer
- default Tokenizer if name not found