Skip to content

Commit c03c17e

Browse files
committed
Fix bad naming of dynamic_type (see #460)
1 parent a01ced8 commit c03c17e

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/DynamicProperty.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,7 @@ public final String locale() {
324324

325325
protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) {
326326

327-
generator.write("type", "{dynamic_property}");
327+
generator.write("type", "{dynamic_type}");
328328
super.serializeInternal(generator, mapper);
329329
if (this.enabled != null) {
330330
generator.writeKey("enabled");

java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/Property.java

+5-5
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public enum Kind implements JsonEnum {
8585

8686
DoubleRange("double_range"),
8787

88-
DynamicProperty("{dynamic_property}"),
88+
DynamicProperty("{dynamic_type}"),
8989

9090
Alias("alias"),
9191

@@ -420,17 +420,17 @@ public DoubleRangeProperty doubleRange() {
420420
}
421421

422422
/**
423-
* Is this variant instance of kind {@code {dynamic_property}}?
423+
* Is this variant instance of kind {@code {dynamic_type}}?
424424
*/
425425
public boolean isDynamicProperty() {
426426
return _kind == Kind.DynamicProperty;
427427
}
428428

429429
/**
430-
* Get the {@code {dynamic_property}} variant value.
430+
* Get the {@code {dynamic_type}} variant value.
431431
*
432432
* @throws IllegalStateException
433-
* if the current variant is not of the {@code {dynamic_property}}
433+
* if the current variant is not of the {@code {dynamic_type}}
434434
* kind.
435435
*/
436436
public DynamicProperty dynamicProperty() {
@@ -1580,7 +1580,7 @@ protected static void setupPropertyDeserializer(ObjectDeserializer<Builder> op)
15801580
op.add(Builder::denseVector, DenseVectorProperty._DESERIALIZER, "dense_vector");
15811581
op.add(Builder::double_, DoubleNumberProperty._DESERIALIZER, "double");
15821582
op.add(Builder::doubleRange, DoubleRangeProperty._DESERIALIZER, "double_range");
1583-
op.add(Builder::dynamicProperty, DynamicProperty._DESERIALIZER, "{dynamic_property}");
1583+
op.add(Builder::dynamicProperty, DynamicProperty._DESERIALIZER, "{dynamic_type}");
15841584
op.add(Builder::alias, FieldAliasProperty._DESERIALIZER, "alias");
15851585
op.add(Builder::flattened, FlattenedProperty._DESERIALIZER, "flattened");
15861586
op.add(Builder::float_, FloatNumberProperty._DESERIALIZER, "float");

java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/PropertyBuilders.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -250,15 +250,15 @@ public static Property doubleRange(Function<DoubleRangeProperty.Builder, ObjectB
250250
}
251251

252252
/**
253-
* Creates a builder for the {@link DynamicProperty {dynamic_property}}
253+
* Creates a builder for the {@link DynamicProperty {dynamic_type}}
254254
* {@code Property} variant.
255255
*/
256256
public static DynamicProperty.Builder dynamicProperty() {
257257
return new DynamicProperty.Builder();
258258
}
259259

260260
/**
261-
* Creates a Property of the {@link DynamicProperty {dynamic_property}}
261+
* Creates a Property of the {@link DynamicProperty {dynamic_type}}
262262
* {@code Property} variant.
263263
*/
264264
public static Property dynamicProperty(Function<DynamicProperty.Builder, ObjectBuilder<DynamicProperty>> fn) {

0 commit comments

Comments
 (0)