internal static ExpressRouteCrossConnectionsRoutesTableSummaryListResult DeserializeExpressRouteCrossConnectionsRoutesTableSummaryListResult(JsonElement element) { Optional <IReadOnlyList <ExpressRouteCrossConnectionRoutesTableSummary> > value = default; Optional <string> nextLink = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("value")) { List <ExpressRouteCrossConnectionRoutesTableSummary> array = new List <ExpressRouteCrossConnectionRoutesTableSummary>(); foreach (var item in property.Value.EnumerateArray()) { array.Add(ExpressRouteCrossConnectionRoutesTableSummary.DeserializeExpressRouteCrossConnectionRoutesTableSummary(item)); } value = array; continue; } if (property.NameEquals("nextLink")) { nextLink = property.Value.GetString(); continue; } } return(new ExpressRouteCrossConnectionsRoutesTableSummaryListResult(Optional.ToList(value), nextLink.Value)); }
internal static ExpressRouteCrossConnectionsRoutesTableSummaryListResult DeserializeExpressRouteCrossConnectionsRoutesTableSummaryListResult(JsonElement element) { IReadOnlyList <ExpressRouteCrossConnectionRoutesTableSummary> value = default; string nextLink = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("value")) { if (property.Value.ValueKind == JsonValueKind.Null) { continue; } List <ExpressRouteCrossConnectionRoutesTableSummary> array = new List <ExpressRouteCrossConnectionRoutesTableSummary>(); foreach (var item in property.Value.EnumerateArray()) { if (item.ValueKind == JsonValueKind.Null) { array.Add(null); } else { array.Add(ExpressRouteCrossConnectionRoutesTableSummary.DeserializeExpressRouteCrossConnectionRoutesTableSummary(item)); } } value = array; continue; } if (property.NameEquals("nextLink")) { if (property.Value.ValueKind == JsonValueKind.Null) { continue; } nextLink = property.Value.GetString(); continue; } } return(new ExpressRouteCrossConnectionsRoutesTableSummaryListResult(value, nextLink)); }