Class AnalyzeRequest.Builder
java.lang.Object
org.opensearch.client.util.ObjectBuilderBase
org.opensearch.client.opensearch._types.RequestBase.AbstractBuilder<AnalyzeRequest.Builder>
org.opensearch.client.opensearch.indices.AnalyzeRequest.Builder
- All Implemented Interfaces:
CopyableBuilder<AnalyzeRequest.Builder,,AnalyzeRequest> MutableBuilder<AnalyzeRequest.Builder,,AnalyzeRequest> ObjectBuilder<AnalyzeRequest>
- Enclosing class:
AnalyzeRequest
public static class AnalyzeRequest.Builder
extends RequestBase.AbstractBuilder<AnalyzeRequest.Builder>
implements CopyableBuilder<AnalyzeRequest.Builder,AnalyzeRequest>
Builder for
AnalyzeRequest.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal AnalyzeRequest.BuilderThe name of the analyzer that should be applied to the providedtext.final AnalyzeRequest.Builderattributes(String value, String... values) Array of token attributes used to filter the output of theexplainparameter.final AnalyzeRequest.Builderattributes(List<String> list) Array of token attributes used to filter the output of theexplainparameter.build()Builds aAnalyzeRequest.final AnalyzeRequest.BuilderArray of character filters used to preprocess characters before the tokenizer.final AnalyzeRequest.BuildercharFilter(List<CharFilter> list) Array of character filters used to preprocess characters before the tokenizer.final AnalyzeRequest.BuildercharFilter(CharFilter value, CharFilter... values) Array of character filters used to preprocess characters before the tokenizer.copy()Create a new builderCopyableBuilderthat is a copy of this one.final AnalyzeRequest.BuilderIftrue, the response includes token attributes and additional details.final AnalyzeRequest.BuilderAPI name:fieldfinal AnalyzeRequest.BuilderArray of token filters used to apply after the tokenizer.final AnalyzeRequest.Builderfilter(List<TokenFilter> list) Array of token filters used to apply after the tokenizer.final AnalyzeRequest.Builderfilter(TokenFilter value, TokenFilter... values) Array of token filters used to apply after the tokenizer.final AnalyzeRequest.BuilderIndex used to derive the analyzer.final AnalyzeRequest.Buildernormalizer(String value) Normalizer to use to convert text into a single token.protected AnalyzeRequest.Builderself()final AnalyzeRequest.BuilderAPI name:textfinal AnalyzeRequest.BuilderAPI name:textfinal AnalyzeRequest.BuilderAPI name:tokenizerfinal AnalyzeRequest.BuilderAPI name:tokenizerMethods inherited from class org.opensearch.client.opensearch._types.RequestBase.AbstractBuilder
errorTrace, humanMethods inherited from class org.opensearch.client.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _listCopy, _mapCopy, _mapPut, _mapPutAllMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.opensearch.client.util.MutableBuilder
applyMutation
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
copy
Description copied from interface:CopyableBuilderCreate a new builderCopyableBuilderthat is a copy of this one.- Specified by:
copyin interfaceCopyableBuilder<AnalyzeRequest.Builder,AnalyzeRequest> - Returns:
- a new builder instance.
-
self
- Specified by:
selfin classRequestBase.AbstractBuilder<AnalyzeRequest.Builder>
-
analyzer
The name of the analyzer that should be applied to the providedtext. This could be a built-in analyzer, or an analyzer that's been configured in the index.API name:
analyzer -
attributes
Array of token attributes used to filter the output of theexplainparameter.API name:
attributesAdds all elements of
listtoattributes. -
attributes
Array of token attributes used to filter the output of theexplainparameter.API name:
attributesAdds one or more values to
attributes. -
charFilter
Array of character filters used to preprocess characters before the tokenizer.API name:
char_filterAdds all elements of
listtocharFilter. -
charFilter
Array of character filters used to preprocess characters before the tokenizer.API name:
char_filterAdds one or more values to
charFilter. -
charFilter
@Nonnull public final AnalyzeRequest.Builder charFilter(Function<CharFilter.Builder, ObjectBuilder<CharFilter>> fn) Array of character filters used to preprocess characters before the tokenizer.API name:
char_filterAdds a value to
charFilterusing a builder lambda. -
explain
Iftrue, the response includes token attributes and additional details.API name:
explain -
field
API name:field -
filter
Array of token filters used to apply after the tokenizer.API name:
filterAdds all elements of
listtofilter. -
filter
Array of token filters used to apply after the tokenizer.API name:
filterAdds one or more values to
filter. -
filter
@Nonnull public final AnalyzeRequest.Builder filter(Function<TokenFilter.Builder, ObjectBuilder<TokenFilter>> fn) Array of token filters used to apply after the tokenizer.API name:
filterAdds a value to
filterusing a builder lambda. -
index
Index used to derive the analyzer. If specified, theanalyzeror field parameter overrides this value. If no index is specified or the index does not have a default analyzer, the analyze API uses the standard analyzer.API name:
index -
normalizer
Normalizer to use to convert text into a single token.API name:
normalizer -
text
API name:textAdds all elements of
listtotext. -
text
API name:textAdds one or more values to
text. -
tokenizer
API name:tokenizer -
tokenizer
@Nonnull public final AnalyzeRequest.Builder tokenizer(Function<Tokenizer.Builder, ObjectBuilder<Tokenizer>> fn) API name:tokenizer -
build
Builds aAnalyzeRequest.- Specified by:
buildin interfaceObjectBuilder<AnalyzeRequest>- Throws:
NullPointerException- if some of the required fields are null.
-