Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 8aec674

Browse files
committedFeb 17, 2025
Improve union (de-)serialization
1 parent 55b8b2e commit 8aec674

File tree

729 files changed

+9683
-9221
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

729 files changed

+9683
-9221
lines changed
 

‎src/Elastic.Clients.Elasticsearch/_Generated/Api/AsyncSearch/AsyncSearchStatusResponse.g.cs

+24-24
Original file line numberDiff line numberDiff line change
@@ -60,62 +60,62 @@ public override AsyncSearchStatusResponse Read(ref System.Text.Json.Utf8JsonRead
6060
LocalJsonValue<long> propStartTimeInMillis = default;
6161
while (reader.Read() && reader.TokenType is System.Text.Json.JsonTokenType.PropertyName)
6262
{
63-
if (propClusters.TryRead(ref reader, options, PropClusters))
63+
if (propClusters.TryReadProperty(ref reader, options, PropClusters, null))
6464
{
6565
continue;
6666
}
6767

68-
if (propCompletionStatus.TryRead(ref reader, options, PropCompletionStatus))
68+
if (propCompletionStatus.TryReadProperty(ref reader, options, PropCompletionStatus, null))
6969
{
7070
continue;
7171
}
7272

73-
if (propCompletionTime.TryRead(ref reader, options, PropCompletionTime))
73+
if (propCompletionTime.TryReadProperty(ref reader, options, PropCompletionTime, null))
7474
{
7575
continue;
7676
}
7777

78-
if (propCompletionTimeInMillis.TryRead(ref reader, options, PropCompletionTimeInMillis))
78+
if (propCompletionTimeInMillis.TryReadProperty(ref reader, options, PropCompletionTimeInMillis, null))
7979
{
8080
continue;
8181
}
8282

83-
if (propExpirationTime.TryRead(ref reader, options, PropExpirationTime))
83+
if (propExpirationTime.TryReadProperty(ref reader, options, PropExpirationTime, null))
8484
{
8585
continue;
8686
}
8787

88-
if (propExpirationTimeInMillis.TryRead(ref reader, options, PropExpirationTimeInMillis))
88+
if (propExpirationTimeInMillis.TryReadProperty(ref reader, options, PropExpirationTimeInMillis, null))
8989
{
9090
continue;
9191
}
9292

93-
if (propId.TryRead(ref reader, options, PropId))
93+
if (propId.TryReadProperty(ref reader, options, PropId, null))
9494
{
9595
continue;
9696
}
9797

98-
if (propIsPartial.TryRead(ref reader, options, PropIsPartial))
98+
if (propIsPartial.TryReadProperty(ref reader, options, PropIsPartial, null))
9999
{
100100
continue;
101101
}
102102

103-
if (propIsRunning.TryRead(ref reader, options, PropIsRunning))
103+
if (propIsRunning.TryReadProperty(ref reader, options, PropIsRunning, null))
104104
{
105105
continue;
106106
}
107107

108-
if (propShards.TryRead(ref reader, options, PropShards))
108+
if (propShards.TryReadProperty(ref reader, options, PropShards, null))
109109
{
110110
continue;
111111
}
112112

113-
if (propStartTime.TryRead(ref reader, options, PropStartTime))
113+
if (propStartTime.TryReadProperty(ref reader, options, PropStartTime, null))
114114
{
115115
continue;
116116
}
117117

118-
if (propStartTimeInMillis.TryRead(ref reader, options, PropStartTimeInMillis))
118+
if (propStartTimeInMillis.TryReadProperty(ref reader, options, PropStartTimeInMillis, null))
119119
{
120120
continue;
121121
}
@@ -155,18 +155,18 @@ public override AsyncSearchStatusResponse Read(ref System.Text.Json.Utf8JsonRead
155155
public override void Write(System.Text.Json.Utf8JsonWriter writer, AsyncSearchStatusResponse value, System.Text.Json.JsonSerializerOptions options)
156156
{
157157
writer.WriteStartObject();
158-
writer.WriteProperty(options, PropClusters, value.Clusters);
159-
writer.WriteProperty(options, PropCompletionStatus, value.CompletionStatus);
160-
writer.WriteProperty(options, PropCompletionTime, value.CompletionTime);
161-
writer.WriteProperty(options, PropCompletionTimeInMillis, value.CompletionTimeInMillis);
162-
writer.WriteProperty(options, PropExpirationTime, value.ExpirationTime);
163-
writer.WriteProperty(options, PropExpirationTimeInMillis, value.ExpirationTimeInMillis);
164-
writer.WriteProperty(options, PropId, value.Id);
165-
writer.WriteProperty(options, PropIsPartial, value.IsPartial);
166-
writer.WriteProperty(options, PropIsRunning, value.IsRunning);
167-
writer.WriteProperty(options, PropShards, value.Shards);
168-
writer.WriteProperty(options, PropStartTime, value.StartTime);
169-
writer.WriteProperty(options, PropStartTimeInMillis, value.StartTimeInMillis);
158+
writer.WriteProperty(options, PropClusters, value.Clusters, null, null);
159+
writer.WriteProperty(options, PropCompletionStatus, value.CompletionStatus, null, null);
160+
writer.WriteProperty(options, PropCompletionTime, value.CompletionTime, null, null);
161+
writer.WriteProperty(options, PropCompletionTimeInMillis, value.CompletionTimeInMillis, null, null);
162+
writer.WriteProperty(options, PropExpirationTime, value.ExpirationTime, null, null);
163+
writer.WriteProperty(options, PropExpirationTimeInMillis, value.ExpirationTimeInMillis, null, null);
164+
writer.WriteProperty(options, PropId, value.Id, null, null);
165+
writer.WriteProperty(options, PropIsPartial, value.IsPartial, null, null);
166+
writer.WriteProperty(options, PropIsRunning, value.IsRunning, null, null);
167+
writer.WriteProperty(options, PropShards, value.Shards, null, null);
168+
writer.WriteProperty(options, PropStartTime, value.StartTime, null, null);
169+
writer.WriteProperty(options, PropStartTimeInMillis, value.StartTimeInMillis, null, null);
170170
writer.WriteEndObject();
171171
}
172172
}

‎src/Elastic.Clients.Elasticsearch/_Generated/Api/AsyncSearch/DeleteAsyncSearchResponse.g.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public override DeleteAsyncSearchResponse Read(ref System.Text.Json.Utf8JsonRead
3838
LocalJsonValue<bool> propAcknowledged = default;
3939
while (reader.Read() && reader.TokenType is System.Text.Json.JsonTokenType.PropertyName)
4040
{
41-
if (propAcknowledged.TryRead(ref reader, options, PropAcknowledged))
41+
if (propAcknowledged.TryReadProperty(ref reader, options, PropAcknowledged, null))
4242
{
4343
continue;
4444
}
@@ -56,7 +56,7 @@ public override DeleteAsyncSearchResponse Read(ref System.Text.Json.Utf8JsonRead
5656
public override void Write(System.Text.Json.Utf8JsonWriter writer, DeleteAsyncSearchResponse value, System.Text.Json.JsonSerializerOptions options)
5757
{
5858
writer.WriteStartObject();
59-
writer.WriteProperty(options, PropAcknowledged, value.Acknowledged);
59+
writer.WriteProperty(options, PropAcknowledged, value.Acknowledged, null, null);
6060
writer.WriteEndObject();
6161
}
6262
}

0 commit comments

Comments
 (0)