Class CustomAnalyzer.ConditionBuilder
java.lang.Object
org.apache.lucene.analysis.custom.CustomAnalyzer.ConditionBuilder
- Enclosing class:
- CustomAnalyzer
Factory class for a
ConditionalTokenFilter
-
Method Summary
Modifier and TypeMethodDescriptionaddTokenFilter
(Class<? extends TokenFilterFactory> factory, String... params) Adds the given token filter.addTokenFilter
(Class<? extends TokenFilterFactory> factory, Map<String, String> params) Adds the given token filter.addTokenFilter
(String name, String... params) Adds the given token filter.addTokenFilter
(String name, Map<String, String> params) Adds the given token filter.endwhen()
Close the branch and return to the main analysis chain
-
Method Details
-
addTokenFilter
public CustomAnalyzer.ConditionBuilder addTokenFilter(String name, Map<String, String> params) throws IOExceptionAdds the given token filter.- Parameters:
name
- is used to look up the factory withTokenFilterFactory.forName(String, Map)
. The list of possible names can be looked up withTokenFilterFactory.availableTokenFilters()
.params
- the map of parameters to be passed to factory. The map must be modifiable.- Throws:
IOException
-
addTokenFilter
public CustomAnalyzer.ConditionBuilder addTokenFilter(String name, String... params) throws IOException Adds the given token filter.- Parameters:
name
- is used to look up the factory withTokenFilterFactory.forName(String, Map)
. The list of possible names can be looked up withTokenFilterFactory.availableTokenFilters()
.params
- the map of parameters to be passed to factory. The map must be modifiable.- Throws:
IOException
-
addTokenFilter
public CustomAnalyzer.ConditionBuilder addTokenFilter(Class<? extends TokenFilterFactory> factory, Map<String, String> params) throws IOExceptionAdds the given token filter.- Parameters:
factory
- class that is used to create the token filter.params
- the map of parameters to be passed to factory. The map must be modifiable.- Throws:
IOException
-
addTokenFilter
public CustomAnalyzer.ConditionBuilder addTokenFilter(Class<? extends TokenFilterFactory> factory, String... params) throws IOException Adds the given token filter.- Parameters:
factory
- class that is used to create the token filter.params
- the map of parameters to be passed to factory. The map must be modifiable.- Throws:
IOException
-
endwhen
Close the branch and return to the main analysis chain- Throws:
IOException
-