diff --git a/java-client/src/main/java/org/opensearch/client/json/PlainDeserializable.java b/java-client/src/main/java/org/opensearch/client/json/PlainDeserializable.java index f5d5a444f4..12793701a4 100644 --- a/java-client/src/main/java/org/opensearch/client/json/PlainDeserializable.java +++ b/java-client/src/main/java/org/opensearch/client/json/PlainDeserializable.java @@ -16,7 +16,7 @@ public interface PlainDeserializable { - B get(); + B self(); /** Updates object with newly provided JSON properties @param parser the JsonParser parser @@ -29,7 +29,7 @@ default B withJson(JsonParser parser, JsonpMapper mapper) { @SuppressWarnings("unchecked") ObjectDeserializer objectDeserializer = (ObjectDeserializer) DelegatingDeserializer.unwrap(deserializer); assert objectDeserializer != null; - return objectDeserializer.deserialize(get(), parser, mapper, parser.next()); + return objectDeserializer.deserialize(self(), parser, mapper, parser.next()); } /** Updates object with newly provided JSON properties diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/_types/ErrorResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/_types/ErrorResponse.java index e59b401d1d..acee4e6551 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/_types/ErrorResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/_types/ErrorResponse.java @@ -39,6 +39,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.json.UnionDeserializer; import org.opensearch.client.util.ApiTypeHelper; @@ -118,7 +119,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link ErrorResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private ErrorCause error; private Integer status; @@ -157,6 +158,11 @@ public ErrorResponse build() { return new ErrorResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/AliasesResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/AliasesResponse.java index 9988b93b0c..18577c248a 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/AliasesResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/AliasesResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.aliases.AliasesRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link AliasesResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public AliasesResponse build() { return new AliasesResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createAliasesResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/AllocationResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/AllocationResponse.java index 0e4c06f275..447fd0c054 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/AllocationResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/AllocationResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.allocation.AllocationRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link AllocationResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public AllocationResponse build() { return new AllocationResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createAllocationResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/ClusterManagerResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/ClusterManagerResponse.java index 2e85797fc9..33ef98e1fe 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/ClusterManagerResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/ClusterManagerResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.cluster_manager.ClusterManagerRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link ClusterManagerResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public ClusterManagerResponse build() { return new ClusterManagerResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createClusterManagerResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/CountResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/CountResponse.java index 435c126280..4bad9efac5 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/CountResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/CountResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.count.CountRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link CountResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public CountResponse build() { return new CountResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createCountResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/FielddataResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/FielddataResponse.java index 47edbd31ce..584aed8271 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/FielddataResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/FielddataResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.fielddata.FielddataRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link FielddataResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public FielddataResponse build() { return new FielddataResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createFielddataResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/HealthResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/HealthResponse.java index e6c9ba92dd..7fa50f5039 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/HealthResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/HealthResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.health.HealthRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link HealthResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public HealthResponse build() { return new HealthResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createHealthResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/HelpResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/HelpResponse.java index 37264d05b3..0a0c73d0ac 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/HelpResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/HelpResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.help.HelpRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link HelpResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public HelpResponse build() { return new HelpResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createHelpResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/IndicesResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/IndicesResponse.java index f8fb10bf5b..7139b9822f 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/IndicesResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/IndicesResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.indices.IndicesRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link IndicesResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public IndicesResponse build() { return new IndicesResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createIndicesResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/NodeattrsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/NodeattrsResponse.java index dd336e44df..9dd8aa6307 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/NodeattrsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/NodeattrsResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.nodeattrs.NodeAttributesRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link NodeattrsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public NodeattrsResponse build() { return new NodeattrsResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createNodeattrsResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/NodesResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/NodesResponse.java index 9843ab40b0..1397f2be35 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/NodesResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/NodesResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.nodes.NodesRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link NodesResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public NodesResponse build() { return new NodesResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createNodesResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/PendingTasksResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/PendingTasksResponse.java index 3d7e4545ab..b3e7600be4 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/PendingTasksResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/PendingTasksResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.pending_tasks.PendingTasksRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link PendingTasksResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public PendingTasksResponse build() { return new PendingTasksResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createPendingTasksResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/PluginsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/PluginsResponse.java index 1c43156668..fc9a79075d 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/PluginsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/PluginsResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.plugins.PluginsRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link PluginsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public PluginsResponse build() { return new PluginsResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createPluginsResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/RecoveryResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/RecoveryResponse.java index 8f38f6a5f5..7556644a42 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/RecoveryResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/RecoveryResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.recovery.RecoveryRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link RecoveryResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public RecoveryResponse build() { return new RecoveryResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createRecoveryResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/RepositoriesResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/RepositoriesResponse.java index 009f736bd9..679a79aaf2 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/RepositoriesResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/RepositoriesResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.repositories.RepositoriesRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link RepositoriesResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public RepositoriesResponse build() { return new RepositoriesResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createRepositoriesResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/SegmentsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/SegmentsResponse.java index b3a6ee422e..0c82e7f173 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/SegmentsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/SegmentsResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.segments.SegmentsRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link SegmentsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public SegmentsResponse build() { return new SegmentsResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createSegmentsResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/ShardsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/ShardsResponse.java index d714051353..3459293a28 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/ShardsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/ShardsResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.shards.ShardsRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link ShardsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public ShardsResponse build() { return new ShardsResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createShardsResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/SnapshotsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/SnapshotsResponse.java index b059a35cec..4ff89692d4 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/SnapshotsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/SnapshotsResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.snapshots.SnapshotsRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link SnapshotsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public SnapshotsResponse build() { return new SnapshotsResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createSnapshotsResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/TasksResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/TasksResponse.java index bff415e614..bdc7f14ca5 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/TasksResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/TasksResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.tasks.TasksRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link TasksResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public TasksResponse build() { return new TasksResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createTasksResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/TemplatesResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/TemplatesResponse.java index f9be18da9e..bc42d42d91 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/TemplatesResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/TemplatesResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.templates.TemplatesRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link TemplatesResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public TemplatesResponse build() { return new TemplatesResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createTemplatesResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/ThreadPoolResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/ThreadPoolResponse.java index 5369159405..219da9a442 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/ThreadPoolResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/ThreadPoolResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cat.thread_pool.ThreadPoolRecord; import org.opensearch.client.util.ApiTypeHelper; @@ -90,7 +91,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link ThreadPoolResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List valueBody; /** @@ -139,6 +140,11 @@ public ThreadPoolResponse build() { return new ThreadPoolResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createThreadPoolResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/count/CountRecord.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/count/CountRecord.java index 93d9867cf2..06e644bc01 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/count/CountRecord.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/count/CountRecord.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.util.ObjectBuilder; import org.opensearch.client.util.ObjectBuilderBase; @@ -136,7 +137,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link CountRecord}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private String epoch; @@ -187,6 +188,11 @@ public CountRecord build() { return new CountRecord(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cat/nodes/NodesRecord.java b/java-client/src/main/java/org/opensearch/client/opensearch/cat/nodes/NodesRecord.java index 3ffe2ce5e1..9bbe342e20 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cat/nodes/NodesRecord.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cat/nodes/NodesRecord.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.util.ObjectBuilder; import org.opensearch.client.util.ObjectBuilderBase; @@ -1925,7 +1926,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link NodesRecord}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private String id; @@ -3201,6 +3202,11 @@ public NodesRecord build() { return new NodesRecord(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/AllocationExplainRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/AllocationExplainRequest.java index a238f9046c..4477edaef7 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/AllocationExplainRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/AllocationExplainRequest.java @@ -288,7 +288,7 @@ public AllocationExplainRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/AllocationExplainResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/AllocationExplainResponse.java index f501708731..53773d468a 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/AllocationExplainResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/AllocationExplainResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cluster.allocation_explain.AllocationDecision; import org.opensearch.client.opensearch.cluster.allocation_explain.ClusterInfo; @@ -500,7 +501,10 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link AllocationExplainResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase + implements + ObjectBuilder, + PlainDeserializable { @Nullable private String allocateExplanation; @@ -872,6 +876,11 @@ public AllocationExplainResponse build() { return new AllocationExplainResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/GetClusterSettingsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/GetClusterSettingsResponse.java index 98824bdf2c..160b22edc0 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/GetClusterSettingsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/GetClusterSettingsResponse.java @@ -42,6 +42,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.util.ApiTypeHelper; import org.opensearch.client.util.ObjectBuilder; @@ -145,7 +146,10 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link GetClusterSettingsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase + implements + ObjectBuilder, + PlainDeserializable { private Map persistent; private Map transient_; @@ -224,6 +228,11 @@ public GetClusterSettingsResponse build() { return new GetClusterSettingsResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/PutClusterSettingsRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/PutClusterSettingsRequest.java index dc4eda1f82..2b89f8b02b 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/PutClusterSettingsRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/PutClusterSettingsRequest.java @@ -336,7 +336,7 @@ public PutClusterSettingsRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/PutComponentTemplateRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/PutComponentTemplateRequest.java index 601f5533df..81f36950f5 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/PutComponentTemplateRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/PutComponentTemplateRequest.java @@ -469,7 +469,7 @@ public PutComponentTemplateRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/RerouteRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/RerouteRequest.java index 808d5c99b1..961d0b1f44 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/RerouteRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/RerouteRequest.java @@ -417,7 +417,7 @@ public RerouteRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/RerouteResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/RerouteResponse.java index db40d31915..a239873005 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/cluster/RerouteResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/cluster/RerouteResponse.java @@ -42,6 +42,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.cluster.reroute.RerouteExplanation; import org.opensearch.client.util.ApiTypeHelper; @@ -119,7 +120,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link RerouteResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private List explanations; @@ -177,6 +178,11 @@ public RerouteResponse build() { return new RerouteResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/BulkResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/BulkResponse.java index f53c1a93d2..8afe645bf6 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/BulkResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/BulkResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.core.bulk.BulkResponseItem; import org.opensearch.client.util.ApiTypeHelper; @@ -145,7 +146,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link BulkResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private Boolean errors; private List items; @@ -219,6 +220,11 @@ public BulkResponse build() { return new BulkResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/ClearScrollRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/ClearScrollRequest.java index f5def2ca5c..2aae7b053d 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/ClearScrollRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/ClearScrollRequest.java @@ -152,7 +152,7 @@ public ClearScrollRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/ClearScrollResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/ClearScrollResponse.java index 3bed54f6a7..71a380077f 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/ClearScrollResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/ClearScrollResponse.java @@ -39,6 +39,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.util.ApiTypeHelper; import org.opensearch.client.util.ObjectBuilder; @@ -104,7 +105,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link ClearScrollResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private Boolean succeeded; private Integer numFreed; @@ -136,6 +137,11 @@ public ClearScrollResponse build() { return new ClearScrollResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/CountResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/CountResponse.java index fdf9cacaf7..f1357e5ad9 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/CountResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/CountResponse.java @@ -39,6 +39,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.ShardStatistics; import org.opensearch.client.util.ApiTypeHelper; @@ -105,7 +106,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link CountResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private Long count; private ShardStatistics shards; @@ -144,6 +145,11 @@ public CountResponse build() { return new CountResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/DeleteByQueryRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/DeleteByQueryRequest.java index 2ff20e391d..6285a6077d 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/DeleteByQueryRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/DeleteByQueryRequest.java @@ -1302,7 +1302,7 @@ public DeleteByQueryRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/DeleteByQueryResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/DeleteByQueryResponse.java index 8c8a32d7bb..51a47e0854 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/DeleteByQueryResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/DeleteByQueryResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.BulkIndexByScrollFailure; import org.opensearch.client.opensearch._types.Retries; @@ -324,7 +325,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link DeleteByQueryResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private Long batches; @@ -518,6 +519,11 @@ public DeleteByQueryResponse build() { return new DeleteByQueryResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/ExplainRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/ExplainRequest.java index b76444a835..46c5f2c7fb 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/ExplainRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/ExplainRequest.java @@ -589,7 +589,7 @@ public ExplainRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/FieldCapsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/FieldCapsResponse.java index fadf403f59..e7576c1071 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/FieldCapsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/FieldCapsResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.core.field_caps.FieldCapability; import org.opensearch.client.util.ApiTypeHelper; @@ -131,7 +132,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link FieldCapsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List indices; private Map> fields; @@ -187,6 +188,11 @@ public FieldCapsResponse build() { return new FieldCapsResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/GetScriptResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/GetScriptResponse.java index 743b5966e8..a0fe15afd9 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/GetScriptResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/GetScriptResponse.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.StoredScript; import org.opensearch.client.util.ApiTypeHelper; @@ -124,7 +125,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link GetScriptResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private String id; private Boolean found; @@ -174,6 +175,11 @@ public GetScriptResponse build() { return new GetScriptResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/GetSourceResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/GetSourceResponse.java index 33bd5199f0..1a3a68a6e2 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/GetSourceResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/GetSourceResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpSerializer; import org.opensearch.client.json.JsonpUtils; import org.opensearch.client.json.NamedDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.util.ApiTypeHelper; import org.opensearch.client.util.ObjectBuilder; @@ -93,7 +94,10 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link GetSourceResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder> { + public static class Builder extends ObjectBuilderBase + implements + ObjectBuilder>, + PlainDeserializable> { private TDocument valueBody; @Nullable @@ -129,6 +133,11 @@ public GetSourceResponse build() { return new GetSourceResponse(this); } + + @Override + public Builder self() { + return this; + } } /** diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/PutScriptRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/PutScriptRequest.java index 03570de1db..0cad84ca0e 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/PutScriptRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/PutScriptRequest.java @@ -309,7 +309,7 @@ public PutScriptRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/RankEvalResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/RankEvalResponse.java index 35c7aead4c..71f6c228af 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/RankEvalResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/RankEvalResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.core.rank_eval.RankEvalMetricDetail; import org.opensearch.client.util.ApiTypeHelper; @@ -142,7 +143,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link RankEvalResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private Double metricScore; private Map details; @@ -228,6 +229,11 @@ public RankEvalResponse build() { return new RankEvalResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexRequest.java index ca6a7c450b..f00b51c56a 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexRequest.java @@ -570,7 +570,7 @@ public ReindexRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexResponse.java index f449db711f..5bf7c83b1d 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.BulkIndexByScrollFailure; import org.opensearch.client.opensearch._types.Retries; @@ -359,7 +360,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link ReindexResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private Long batches; @@ -582,6 +583,11 @@ public ReindexResponse build() { return new ReindexResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexRethrottleResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexRethrottleResponse.java index d8e43cc967..ad726a8a32 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexRethrottleResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/ReindexRethrottleResponse.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.core.reindex_rethrottle.ReindexNode; import org.opensearch.client.util.ApiTypeHelper; @@ -102,7 +103,10 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link ReindexRethrottleResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase + implements + ObjectBuilder, + PlainDeserializable { private Map nodes; /** @@ -145,6 +149,11 @@ public ReindexRethrottleResponse build() { return new ReindexRethrottleResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/RenderSearchTemplateRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/RenderSearchTemplateRequest.java index 6d951b63c9..572e1f6773 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/RenderSearchTemplateRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/RenderSearchTemplateRequest.java @@ -240,7 +240,7 @@ public RenderSearchTemplateRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/ScrollRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/ScrollRequest.java index 113bc03c72..f7a09bb9f0 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/ScrollRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/ScrollRequest.java @@ -170,7 +170,7 @@ public ScrollRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchRequest.java index e26239fd1c..ef52d1c73b 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchRequest.java @@ -2249,7 +2249,7 @@ public SearchRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchShardsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchShardsResponse.java index 10d28a4cf7..431eb7bbec 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchShardsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchShardsResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.NodeAttributes; import org.opensearch.client.opensearch._types.NodeShard; @@ -153,7 +154,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link SearchShardsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private Map nodes; private List> shards; @@ -249,6 +250,11 @@ public SearchShardsResponse build() { return new SearchShardsResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchTemplateRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchTemplateRequest.java index b4a712cd29..447772e1bd 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchTemplateRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/SearchTemplateRequest.java @@ -670,7 +670,7 @@ public SearchTemplateRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/TermsEnumResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/TermsEnumResponse.java index 2909698699..1bb16d647a 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/TermsEnumResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/TermsEnumResponse.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.ShardStatistics; import org.opensearch.client.util.ApiTypeHelper; @@ -126,7 +127,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link TermsEnumResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private ShardStatistics shards; private List terms; @@ -187,6 +188,11 @@ public TermsEnumResponse build() { return new TermsEnumResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/TermvectorsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/TermvectorsResponse.java index c644b5df7f..a48d03b5c4 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/TermvectorsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/TermvectorsResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.core.termvectors.TermVector; import org.opensearch.client.util.ApiTypeHelper; @@ -167,7 +168,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link TermvectorsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private Boolean found; private String id; @@ -261,6 +262,11 @@ public TermvectorsResponse build() { return new TermvectorsResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryRequest.java index caae46c91c..ed403cb38f 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryRequest.java @@ -1371,7 +1371,7 @@ public UpdateByQueryRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryResponse.java index 1fc80b1523..7583511759 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.BulkIndexByScrollFailure; import org.opensearch.client.opensearch._types.Retries; @@ -324,7 +325,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link UpdateByQueryResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private Long batches; @@ -518,6 +519,11 @@ public UpdateByQueryResponse build() { return new UpdateByQueryResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryRethrottleResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryRethrottleResponse.java index 2b6d3ff20a..b6c538286a 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryRethrottleResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/core/UpdateByQueryRethrottleResponse.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.core.update_by_query_rethrottle.UpdateByQueryRethrottleNode; import org.opensearch.client.util.ApiTypeHelper; @@ -102,7 +103,10 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link UpdateByQueryRethrottleResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase + implements + ObjectBuilder, + PlainDeserializable { private Map nodes; /** @@ -148,6 +152,11 @@ public UpdateByQueryRethrottleResponse build() { return new UpdateByQueryRethrottleResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/AnalyzeResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/AnalyzeResponse.java index 8c46aad120..405c182f10 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/AnalyzeResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/AnalyzeResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.indices.analyze.AnalyzeDetail; import org.opensearch.client.opensearch.indices.analyze.AnalyzeToken; @@ -120,7 +121,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link AnalyzeResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private AnalyzeDetail detail; @@ -182,6 +183,11 @@ public AnalyzeResponse build() { return new AnalyzeResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/CloneIndexRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/CloneIndexRequest.java index de12df4ed3..7d7d989480 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/CloneIndexRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/CloneIndexRequest.java @@ -404,7 +404,7 @@ public CloneIndexRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/CreateIndexRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/CreateIndexRequest.java index a8a8eb4527..bfbecbc763 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/CreateIndexRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/CreateIndexRequest.java @@ -419,7 +419,7 @@ public CreateIndexRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/CreateIndexResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/CreateIndexResponse.java index 1773f5e9e4..742071c885 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/CreateIndexResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/CreateIndexResponse.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.util.ApiTypeHelper; import org.opensearch.client.util.ObjectBuilder; @@ -123,7 +124,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link CreateIndexResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private String index; private Boolean shardsAcknowledged; @@ -166,6 +167,11 @@ public CreateIndexResponse build() { return new CreateIndexResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/DataStreamsStatsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/DataStreamsStatsResponse.java index c646cc90de..23c8f84f8c 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/DataStreamsStatsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/DataStreamsStatsResponse.java @@ -17,6 +17,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.ShardStatistics; import org.opensearch.client.util.ApiTypeHelper; @@ -147,7 +148,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link DataStreamsStatsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private ShardStatistics shards; @@ -243,6 +244,11 @@ public DataStreamsStatsResponse build() { return new DataStreamsStatsResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/DiskUsageResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/DiskUsageResponse.java index d7bed4f65d..13e7e4aef3 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/DiskUsageResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/DiskUsageResponse.java @@ -38,6 +38,7 @@ import org.opensearch.client.json.JsonpDeserializable; import org.opensearch.client.json.JsonpDeserializer; import org.opensearch.client.json.JsonpMapper; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.util.ApiTypeHelper; import org.opensearch.client.util.ObjectBuilder; @@ -84,7 +85,7 @@ public void serialize(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link DiskUsageResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private JsonData valueBody; /** @@ -108,6 +109,11 @@ public DiskUsageResponse build() { return new DiskUsageResponse(this); } + + @Override + public Builder self() { + return this; + } } public static final JsonpDeserializer _DESERIALIZER = createDiskUsageResponseDeserializer(); diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/GetIndexTemplateResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/GetIndexTemplateResponse.java index 709b613233..f0035d6bf4 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/GetIndexTemplateResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/GetIndexTemplateResponse.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.indices.get_index_template.IndexTemplateItem; import org.opensearch.client.util.ApiTypeHelper; @@ -101,7 +102,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link GetIndexTemplateResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List indexTemplates; /** @@ -144,6 +145,11 @@ public GetIndexTemplateResponse build() { return new GetIndexTemplateResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/GetUpgradeResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/GetUpgradeResponse.java index a290895165..81e962f5a9 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/GetUpgradeResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/GetUpgradeResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.util.ApiTypeHelper; import org.opensearch.client.util.ObjectBuilder; @@ -123,7 +124,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link GetUpgradeResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private List overlapping; @@ -197,6 +198,11 @@ public GetUpgradeResponse build() { return new GetUpgradeResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/IndicesStatsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/IndicesStatsResponse.java index e2f40cb537..065bd3a702 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/IndicesStatsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/IndicesStatsResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.ShardStatistics; import org.opensearch.client.opensearch.indices.stats.IndicesStats; @@ -129,7 +130,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link IndicesStatsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private Map indices; @@ -207,6 +208,11 @@ public IndicesStatsResponse build() { return new IndicesStatsResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/PutIndexTemplateRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/PutIndexTemplateRequest.java index f080df19ca..638409725b 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/PutIndexTemplateRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/PutIndexTemplateRequest.java @@ -381,7 +381,7 @@ public PutIndexTemplateRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/PutTemplateRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/PutTemplateRequest.java index 668ed92641..20636c7bf8 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/PutTemplateRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/PutTemplateRequest.java @@ -574,7 +574,7 @@ public PutTemplateRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/ResolveIndexResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/ResolveIndexResponse.java index 3d42e6eaaa..2957895360 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/ResolveIndexResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/ResolveIndexResponse.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.indices.resolve_index.ResolveIndexAliasItem; import org.opensearch.client.opensearch.indices.resolve_index.ResolveIndexItem; @@ -122,7 +123,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link ResolveIndexResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private List indices; private List aliases; @@ -196,6 +197,11 @@ public ResolveIndexResponse build() { return new ResolveIndexResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/SegmentsResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/SegmentsResponse.java index a9bef40235..7635e89914 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/SegmentsResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/SegmentsResponse.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.ShardStatistics; import org.opensearch.client.opensearch.indices.segments.IndexSegment; @@ -115,7 +116,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link SegmentsResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private Map indices; private ShardStatistics shards; @@ -175,6 +176,11 @@ public SegmentsResponse build() { return new SegmentsResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/ShardStoresResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/ShardStoresResponse.java index 4466c02edd..6b7583fe2c 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/ShardStoresResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/ShardStoresResponse.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch.indices.shard_stores.IndicesShardStores; import org.opensearch.client.util.ApiTypeHelper; @@ -102,7 +103,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link ShardStoresResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private Map indices; /** @@ -145,6 +146,11 @@ public ShardStoresResponse build() { return new ShardStoresResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/UpdateAliasesRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/UpdateAliasesRequest.java index fca96df2ca..350575b568 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/UpdateAliasesRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/UpdateAliasesRequest.java @@ -273,7 +273,7 @@ public UpdateAliasesRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/indices/ValidateQueryResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/indices/ValidateQueryResponse.java index af16f7c178..7cd5c37890 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/indices/ValidateQueryResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/indices/ValidateQueryResponse.java @@ -41,6 +41,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.ShardStatistics; import org.opensearch.client.opensearch.indices.validate_query.IndicesValidationExplanation; @@ -150,7 +151,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link ValidateQueryResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private List explanations; @@ -233,6 +234,11 @@ public ValidateQueryResponse build() { return new ValidateQueryResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/nodes/ReloadSecureSettingsRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/nodes/ReloadSecureSettingsRequest.java index f7b2c24937..bd17e4f4a2 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/nodes/ReloadSecureSettingsRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/nodes/ReloadSecureSettingsRequest.java @@ -216,7 +216,7 @@ public ReloadSecureSettingsRequest build() { } @Override - public Builder get() { + public Builder self() { return null; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/snapshot/CreateSnapshotRequest.java b/java-client/src/main/java/org/opensearch/client/opensearch/snapshot/CreateSnapshotRequest.java index fe74d3a2e8..0d4afcd20d 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/snapshot/CreateSnapshotRequest.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/snapshot/CreateSnapshotRequest.java @@ -557,7 +557,7 @@ public CreateSnapshotRequest build() { } @Override - public Builder get() { + public Builder self() { return this; } } diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/tasks/CancelResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/tasks/CancelResponse.java index abe4da1157..88662fb671 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/tasks/CancelResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/tasks/CancelResponse.java @@ -42,6 +42,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.ErrorCause; import org.opensearch.client.util.ApiTypeHelper; @@ -124,7 +125,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link CancelResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { @Nullable private List nodeFailures; @@ -199,6 +200,11 @@ public CancelResponse build() { return new CancelResponse(this); } + + @Override + public Builder self() { + return this; + } } // --------------------------------------------------------------------------------------------- diff --git a/java-client/src/main/java/org/opensearch/client/opensearch/tasks/GetTasksResponse.java b/java-client/src/main/java/org/opensearch/client/opensearch/tasks/GetTasksResponse.java index 00b4878d81..bd9095a3ae 100644 --- a/java-client/src/main/java/org/opensearch/client/opensearch/tasks/GetTasksResponse.java +++ b/java-client/src/main/java/org/opensearch/client/opensearch/tasks/GetTasksResponse.java @@ -40,6 +40,7 @@ import org.opensearch.client.json.JsonpMapper; import org.opensearch.client.json.ObjectBuilderDeserializer; import org.opensearch.client.json.ObjectDeserializer; +import org.opensearch.client.json.PlainDeserializable; import org.opensearch.client.json.PlainJsonSerializable; import org.opensearch.client.opensearch._types.ErrorCause; import org.opensearch.client.util.ApiTypeHelper; @@ -141,7 +142,7 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { * Builder for {@link GetTasksResponse}. */ - public static class Builder extends ObjectBuilderBase implements ObjectBuilder { + public static class Builder extends ObjectBuilderBase implements ObjectBuilder, PlainDeserializable { private Boolean completed; private Info task; @@ -216,6 +217,11 @@ public GetTasksResponse build() { return new GetTasksResponse(this); } + + @Override + public Builder self() { + return this; + } } // ---------------------------------------------------------------------------------------------