Class TermvectorsRequest.Builder<TDocument>
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<BuilderT>
co.elastic.clients.elasticsearch._types.RequestBase.AbstractBuilder<TermvectorsRequest.Builder<TDocument>>
co.elastic.clients.elasticsearch.core.TermvectorsRequest.Builder<TDocument>
- All Implemented Interfaces:
WithJson<TermvectorsRequest.Builder<TDocument>>,ObjectBuilder<TermvectorsRequest<TDocument>>
- Enclosing class:
- TermvectorsRequest<TDocument>
public static class TermvectorsRequest.Builder<TDocument>
extends RequestBase.AbstractBuilder<TermvectorsRequest.Builder<TDocument>>
implements ObjectBuilder<TermvectorsRequest<TDocument>>
Builder for
TermvectorsRequest.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds aTermvectorsRequest.An artificial document (a document not present in the index) for which you want to retrieve term vectors.Comma-separated list or wildcard expressions of fields to include in the statistics.Comma-separated list or wildcard expressions of fields to include in the statistics.fieldStatistics(Boolean value) Iftrue, the response includes the document count, sum of document frequencies, and sum of total term frequencies.Filter terms based on their tf-idf scores.Filter terms based on their tf-idf scores.Unique identifier of the document.Required - Name of the index that contains the document.Iftrue, the response includes term offsets.Iftrue, the response includes term payloads.perFieldAnalyzer(String key, String value) Overrides the default per-field analyzer.perFieldAnalyzer(Map<String, String> map) Overrides the default per-field analyzer.Iftrue, the response includes term positions.preference(String value) Specifies the node or shard the operation should be performed on.If true, the request is real-time as opposed to near-real-time.Custom value used to route operations to a specific shard.protected TermvectorsRequest.Builder<TDocument>self()Serializer for TDocument.termStatistics(Boolean value) Iftrue, the response includes term frequency and document frequency.Iftrue, returns the document version as part of a hit.versionType(VersionType value) Specific version type.Methods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJsonMethods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
doc
An artificial document (a document not present in the index) for which you want to retrieve term vectors.API name:
doc -
fieldStatistics
Iftrue, the response includes the document count, sum of document frequencies, and sum of total term frequencies.API name:
field_statistics -
fields
Comma-separated list or wildcard expressions of fields to include in the statistics. Used as the default list unless a specific field list is provided in thecompletion_fieldsorfielddata_fieldsparameters.API name:
fieldsAdds all elements of
listtofields. -
fields
Comma-separated list or wildcard expressions of fields to include in the statistics. Used as the default list unless a specific field list is provided in thecompletion_fieldsorfielddata_fieldsparameters.API name:
fieldsAdds one or more values to
fields. -
filter
Filter terms based on their tf-idf scores.API name:
filter -
filter
public final TermvectorsRequest.Builder<TDocument> filter(Function<Filter.Builder, ObjectBuilder<Filter>> fn) Filter terms based on their tf-idf scores.API name:
filter -
id
Unique identifier of the document.API name:
id -
index
Required - Name of the index that contains the document.API name:
index -
offsets
Iftrue, the response includes term offsets.API name:
offsets -
payloads
Iftrue, the response includes term payloads.API name:
payloads -
perFieldAnalyzer
Overrides the default per-field analyzer.API name:
per_field_analyzerAdds all entries of
maptoperFieldAnalyzer. -
perFieldAnalyzer
Overrides the default per-field analyzer.API name:
per_field_analyzerAdds an entry to
perFieldAnalyzer. -
positions
Iftrue, the response includes term positions.API name:
positions -
preference
Specifies the node or shard the operation should be performed on. Random by default.API name:
preference -
realtime
If true, the request is real-time as opposed to near-real-time.API name:
realtime -
routing
Custom value used to route operations to a specific shard.API name:
routing -
termStatistics
Iftrue, the response includes term frequency and document frequency.API name:
term_statistics -
version
Iftrue, returns the document version as part of a hit.API name:
version -
versionType
Specific version type.API name:
version_type -
tDocumentSerializer
public final TermvectorsRequest.Builder<TDocument> tDocumentSerializer(@Nullable JsonpSerializer<TDocument> value) Serializer for TDocument. If not set, an attempt will be made to find a serializer from the JSON context. -
self
- Specified by:
selfin classRequestBase.AbstractBuilder<TermvectorsRequest.Builder<TDocument>>
-
build
Builds aTermvectorsRequest.- Specified by:
buildin interfaceObjectBuilder<TDocument>- Throws:
NullPointerException- if some of the required fields are null.
-