Class AnalyzeRequestBuilder
- java.lang.Object
-
- org.elasticsearch.action.ActionRequestBuilder<Request,Response>
-
- org.elasticsearch.action.support.single.shard.SingleShardOperationRequestBuilder<AnalyzeAction.Request,AnalyzeAction.Response,AnalyzeRequestBuilder>
-
- org.elasticsearch.action.admin.indices.analyze.AnalyzeRequestBuilder
-
public class AnalyzeRequestBuilder extends SingleShardOperationRequestBuilder<AnalyzeAction.Request,AnalyzeAction.Response,AnalyzeRequestBuilder>
-
-
Field Summary
-
Fields inherited from class org.elasticsearch.action.ActionRequestBuilder
action, client, request
-
-
Constructor Summary
Constructors Constructor Description AnalyzeRequestBuilder(ElasticsearchClient client, AnalyzeAction action)AnalyzeRequestBuilder(ElasticsearchClient client, AnalyzeAction action, String index, String... text)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AnalyzeRequestBuilderaddCharFilter(String tokenFilter)Add a name of char filter that will be used before the tokenizer.AnalyzeRequestBuilderaddCharFilter(Map<String,?> charFilter)Add char filter setting that will be used on top of a tokenizer provided.AnalyzeRequestBuilderaddTokenFilter(String tokenFilter)Add a name of token filter that will be used on top of a tokenizer provided.AnalyzeRequestBuilderaddTokenFilter(Map<String,?> tokenFilter)Add token filter setting that will be used on top of a tokenizer provided.AnalyzeRequestBuildersetAnalyzer(String analyzer)Sets the analyzer name to use in order to analyze the text.AnalyzeRequestBuildersetAttributes(String... attributes)Sets attributes that will include resultsAnalyzeRequestBuildersetExplain(boolean explain)Sets explainAnalyzeRequestBuildersetField(String field)Sets the field that its analyzer will be used to analyze the text.AnalyzeRequestBuildersetNormalizer(String normalizer)Instead of setting the analyzer and tokenizer, sets the normalizer as nameAnalyzeRequestBuildersetText(String... texts)Sets texts to analyzeAnalyzeRequestBuildersetTokenizer(String tokenizer)Instead of setting the analyzer, sets the tokenizer as name that will be used as part of a custom analyzer.AnalyzeRequestBuildersetTokenizer(Map<String,?> tokenizer)Instead of setting the analyzer, sets the tokenizer using custom settings that will be used as part of a custom analyzer.-
Methods inherited from class org.elasticsearch.action.support.single.shard.SingleShardOperationRequestBuilder
setIndex
-
-
-
-
Constructor Detail
-
AnalyzeRequestBuilder
public AnalyzeRequestBuilder(ElasticsearchClient client, AnalyzeAction action)
-
AnalyzeRequestBuilder
public AnalyzeRequestBuilder(ElasticsearchClient client, AnalyzeAction action, String index, String... text)
-
-
Method Detail
-
setAnalyzer
public AnalyzeRequestBuilder setAnalyzer(String analyzer)
Sets the analyzer name to use in order to analyze the text.- Parameters:
analyzer- The analyzer name.
-
setField
public AnalyzeRequestBuilder setField(String field)
Sets the field that its analyzer will be used to analyze the text. Note, requires an index to be set.
-
setTokenizer
public AnalyzeRequestBuilder setTokenizer(String tokenizer)
Instead of setting the analyzer, sets the tokenizer as name that will be used as part of a custom analyzer.
-
setTokenizer
public AnalyzeRequestBuilder setTokenizer(Map<String,?> tokenizer)
Instead of setting the analyzer, sets the tokenizer using custom settings that will be used as part of a custom analyzer.
-
addTokenFilter
public AnalyzeRequestBuilder addTokenFilter(Map<String,?> tokenFilter)
Add token filter setting that will be used on top of a tokenizer provided.
-
addTokenFilter
public AnalyzeRequestBuilder addTokenFilter(String tokenFilter)
Add a name of token filter that will be used on top of a tokenizer provided.
-
addCharFilter
public AnalyzeRequestBuilder addCharFilter(Map<String,?> charFilter)
Add char filter setting that will be used on top of a tokenizer provided.
-
addCharFilter
public AnalyzeRequestBuilder addCharFilter(String tokenFilter)
Add a name of char filter that will be used before the tokenizer.
-
setExplain
public AnalyzeRequestBuilder setExplain(boolean explain)
Sets explain
-
setAttributes
public AnalyzeRequestBuilder setAttributes(String... attributes)
Sets attributes that will include results
-
setText
public AnalyzeRequestBuilder setText(String... texts)
Sets texts to analyze
-
setNormalizer
public AnalyzeRequestBuilder setNormalizer(String normalizer)
Instead of setting the analyzer and tokenizer, sets the normalizer as name
-
-