Class SimulateTemplateRequest.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.elasticsearch.indices.SimulateTemplateRequest.Builder
- All Implemented Interfaces:
ObjectBuilder<SimulateTemplateRequest>
- Enclosing class:
- SimulateTemplateRequest
public static class SimulateTemplateRequest.Builder extends ObjectBuilderBase implements ObjectBuilder<SimulateTemplateRequest>
Builder for
SimulateTemplateRequest.-
Constructor Summary
Constructors Constructor Description Builder() -
Method Summary
Modifier and Type Method Description SimulateTemplateRequestbuild()Builds aSimulateTemplateRequest.SimulateTemplateRequest.Buildercreate(java.lang.Boolean value)If true, the template passed in the body is only used if no existing templates match the same index patterns.SimulateTemplateRequest.BuildermasterTimeout(Time value)Period to wait for a connection to the master node.SimulateTemplateRequest.BuildermasterTimeout(java.util.function.Function<Time.Builder,ObjectBuilder<Time>> fn)Period to wait for a connection to the master node.SimulateTemplateRequest.Buildername(java.lang.String value)Name of the index template to simulate.SimulateTemplateRequest.Buildertemplate(IndexTemplate value)Required - Request body.SimulateTemplateRequest.Buildertemplate(java.util.function.Function<IndexTemplate.Builder,ObjectBuilder<IndexTemplate>> fn)Required - Request body.Methods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAllMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
create
If true, the template passed in the body is only used if no existing templates match the same index patterns. If false, the simulation uses the template with the highest priority. Note that the template is not permanently added or updated in either case; it is only used for the simulation.API name:
create -
masterTimeout
Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error.API name:
master_timeout -
masterTimeout
public final SimulateTemplateRequest.Builder masterTimeout(java.util.function.Function<Time.Builder,ObjectBuilder<Time>> fn)Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error.API name:
master_timeout -
name
Name of the index template to simulate. To test a template configuration before you add it to the cluster, omit this parameter and specify the template configuration in the request body.API name:
name -
template
Required - Request body.API name:
_value_body -
template
public final SimulateTemplateRequest.Builder template(java.util.function.Function<IndexTemplate.Builder,ObjectBuilder<IndexTemplate>> fn)Required - Request body.API name:
_value_body -
build
Builds aSimulateTemplateRequest.- Specified by:
buildin interfaceObjectBuilder<SimulateTemplateRequest>- Throws:
java.lang.NullPointerException- if some of the required fields are null.
-