Class PutScriptRequest.Builder
java.lang.Object
org.opensearch.client.util.ObjectBuilderBase
org.opensearch.client.opensearch._types.RequestBase.AbstractBuilder<PutScriptRequest.Builder>
org.opensearch.client.opensearch.core.PutScriptRequest.Builder
- All Implemented Interfaces:
CopyableBuilder<PutScriptRequest.Builder,,PutScriptRequest> MutableBuilder<PutScriptRequest.Builder,,PutScriptRequest> ObjectBuilder<PutScriptRequest>
- Enclosing class:
PutScriptRequest
public static class PutScriptRequest.Builder
extends RequestBase.AbstractBuilder<PutScriptRequest.Builder>
implements CopyableBuilder<PutScriptRequest.Builder,PutScriptRequest>
Builder for
PutScriptRequest.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds aPutScriptRequest.final PutScriptRequest.BuilderOperation timeout for connection to cluster-manager node.final PutScriptRequest.BuilderclusterManagerTimeout(Time value) Operation timeout for connection to cluster-manager node.final PutScriptRequest.BuilderContext in which the script or search template should run.copy()Create a new builderCopyableBuilderthat is a copy of this one.final PutScriptRequest.BuilderRequired - Identifier for the stored script or search template.final PutScriptRequest.BuilderDeprecated.final PutScriptRequest.BuildermasterTimeout(Time value) Deprecated.final PutScriptRequest.BuilderRequired - API name:scriptfinal PutScriptRequest.Builderscript(StoredScript value) Required - API name:scriptprotected PutScriptRequest.Builderself()final PutScriptRequest.BuilderPeriod to wait for a response.final PutScriptRequest.BuilderPeriod to wait for a response.Methods 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<PutScriptRequest.Builder,PutScriptRequest> - Returns:
- a new builder instance.
-
self
- Specified by:
selfin classRequestBase.AbstractBuilder<PutScriptRequest.Builder>
-
clusterManagerTimeout
Operation timeout for connection to cluster-manager node.API name:
cluster_manager_timeout -
clusterManagerTimeout
@Nonnull public final PutScriptRequest.Builder clusterManagerTimeout(Function<Time.Builder, ObjectBuilder<Time>> fn) Operation timeout for connection to cluster-manager node.API name:
cluster_manager_timeout -
context
Context in which the script or search template should run. To prevent errors, the API immediately compiles the script or template in this context.API name:
context -
id
Required - Identifier for the stored script or search template. Must be unique within the cluster.API name:
id -
masterTimeout
Deprecated.Period to wait for a connection to the cluster-manager node. If no response is received before the timeout expires, the request fails and returns an error.API name:
master_timeout -
masterTimeout
@Deprecated @Nonnull public final PutScriptRequest.Builder masterTimeout(Function<Time.Builder, ObjectBuilder<Time>> fn) Deprecated.Period to wait for a connection to the cluster-manager node. If no response is received before the timeout expires, the request fails and returns an error.API name:
master_timeout -
script
Required - API name:script -
script
@Nonnull public final PutScriptRequest.Builder script(Function<StoredScript.Builder, ObjectBuilder<StoredScript>> fn) Required - API name:script -
timeout
Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error.API name:
timeout -
timeout
@Nonnull public final PutScriptRequest.Builder timeout(Function<Time.Builder, ObjectBuilder<Time>> fn) Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error.API name:
timeout -
build
Builds aPutScriptRequest.- Specified by:
buildin interfaceObjectBuilder<PutScriptRequest>- Throws:
NullPointerException- if some of the required fields are null.
-