internal static IndexDocumentsResult DeserializeIndexDocumentsResult(JsonElement element)
        {
            IReadOnlyList <IndexingResult> value = default;

            foreach (var property in element.EnumerateObject())
            {
                if (property.NameEquals("value"))
                {
                    List <IndexingResult> array = new List <IndexingResult>();
                    foreach (var item in property.Value.EnumerateArray())
                    {
                        if (item.ValueKind == JsonValueKind.Null)
                        {
                            array.Add(null);
                        }
                        else
                        {
                            array.Add(IndexingResult.DeserializeIndexingResult(item));
                        }
                    }
                    value = array;
                    continue;
                }
            }
            return(new IndexDocumentsResult(value));
        }
        internal static IndexDocumentsResult DeserializeIndexDocumentsResult(JsonElement element)
        {
            IndexDocumentsResult result = new IndexDocumentsResult();

            foreach (var property in element.EnumerateObject())
            {
                if (property.NameEquals("value"))
                {
                    foreach (var item in property.Value.EnumerateArray())
                    {
                        result.Results.Add(IndexingResult.DeserializeIndexingResult(item));
                    }
                    continue;
                }
            }
            return(result);
        }