Class RecoveryResponse.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<RecoveryResponse.Builder>
co.elastic.clients.elasticsearch.cat.RecoveryResponse.Builder
- All Implemented Interfaces:
WithJson<RecoveryResponse.Builder>
,ObjectBuilder<RecoveryResponse>
- Enclosing class:
- RecoveryResponse
public static class RecoveryResponse.Builder extends WithJsonObjectBuilderBase<RecoveryResponse.Builder> implements ObjectBuilder<RecoveryResponse>
Builder for
RecoveryResponse
.-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
Modifier and Type Method Description RecoveryResponse
build()
Builds aRecoveryResponse
.protected RecoveryResponse.Builder
self()
RecoveryResponse.Builder
valueBody(RecoveryRecord value, RecoveryRecord... values)
Required - Response value.RecoveryResponse.Builder
valueBody(java.util.function.Function<RecoveryRecord.Builder,ObjectBuilder<RecoveryRecord>> fn)
Required - Response value.RecoveryResponse.Builder
valueBody(java.util.List<RecoveryRecord> list)
Required - Response value.RecoveryResponse.Builder
withJson(jakarta.json.stream.JsonParser parser, JsonpMapper mapper)
Sets additional properties values on this object by reading from a JSON input.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
-
valueBody
Required - Response value.API name:
_value_body
Adds all elements of
list
tovalueBody
. -
valueBody
Required - Response value.API name:
_value_body
Adds one or more values to
valueBody
. -
valueBody
public final RecoveryResponse.Builder valueBody(java.util.function.Function<RecoveryRecord.Builder,ObjectBuilder<RecoveryRecord>> fn)Required - Response value.API name:
_value_body
Adds a value to
valueBody
using a builder lambda. -
withJson
public RecoveryResponse.Builder withJson(jakarta.json.stream.JsonParser parser, JsonpMapper mapper)Description copied from interface:WithJson
Sets additional properties values on this object by reading from a JSON input.This is a "partial deserialization": properties that were already set keep their value if they're not present in the JSON input, and properties can also be set after having called this method, including overriding those read from the JSON input.
This low level variant of
withJson
gives full control on the json parser and object mapper. Most of the time usingWithJson.withJson(Reader)
andWithJson.withJson(InputStream)
will be more convenient.- Specified by:
withJson
in interfaceWithJson<RecoveryResponse.Builder>
- Overrides:
withJson
in classWithJsonObjectBuilderBase<RecoveryResponse.Builder>
- Parameters:
parser
- the JSONP parsermapper
- the JSONP mapper used to deserialize values and nested objects- Returns:
- this object
-
self
- Specified by:
self
in classWithJsonObjectBuilderBase<RecoveryResponse.Builder>
-
build
Builds aRecoveryResponse
.- Specified by:
build
in interfaceObjectBuilder<RecoveryResponse>
- Throws:
java.lang.NullPointerException
- if some of the required fields are null.
-