Class CompletionContext.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<CompletionContext.Builder>
co.elastic.clients.elasticsearch.core.search.CompletionContext.Builder
- All Implemented Interfaces:
WithJson<CompletionContext.Builder>
,ObjectBuilder<CompletionContext>
- Enclosing class:
- CompletionContext
public static class CompletionContext.Builder extends WithJsonObjectBuilderBase<CompletionContext.Builder> implements ObjectBuilder<CompletionContext>
Builder for
CompletionContext
.-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
Methods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJson
Methods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
boost
API name:boost
-
context
Required - API name:context
-
context
public final CompletionContext.Builder context(java.util.function.Function<Context.Builder,ObjectBuilder<Context>> fn)Required - API name:context
-
neighbours
API name:neighbours
Adds all elements of
list
toneighbours
. -
neighbours
public final CompletionContext.Builder neighbours(GeoHashPrecision value, GeoHashPrecision... values)API name:neighbours
Adds one or more values to
neighbours
. -
neighbours
public final CompletionContext.Builder neighbours(java.util.function.Function<GeoHashPrecision.Builder,ObjectBuilder<GeoHashPrecision>> fn)API name:neighbours
Adds a value to
neighbours
using a builder lambda. -
precision
API name:precision
-
precision
public final CompletionContext.Builder precision(java.util.function.Function<GeoHashPrecision.Builder,ObjectBuilder<GeoHashPrecision>> fn)API name:precision
-
prefix
API name:prefix
-
self
- Specified by:
self
in classWithJsonObjectBuilderBase<CompletionContext.Builder>
-
build
Builds aCompletionContext
.- Specified by:
build
in interfaceObjectBuilder<CompletionContext>
- Throws:
java.lang.NullPointerException
- if some of the required fields are null.
-