From 63dc0915483b1996ec1c94ecc391025ce15a8c04 Mon Sep 17 00:00:00 2001 From: Alan Zimmer <48699787+alzimmermsft@users.noreply.github.com> Date: Wed, 9 Jun 2021 13:12:54 -0700 Subject: [PATCH] Update azure-search-documents After Release (#22176) --- eng/jacoco-test-coverage/pom.xml | 2 +- eng/versioning/version_client.txt | 2 +- .../azure-search-documents/CHANGELOG.md | 32 ++++++++- sdk/search/azure-search-documents/README.md | 2 +- sdk/search/azure-search-documents/pom.xml | 2 +- .../models/AsciiFoldingTokenFilter.java | 6 +- .../models/CjkBigramTokenFilter.java | 6 +- .../models/ClassicTokenizer.java | 6 +- .../models/CommonGramTokenFilter.java | 6 +- .../DictionaryDecompounderTokenFilter.java | 6 +- .../models/EdgeNGramTokenFilter.java | 6 +- .../models/EdgeNGramTokenFilterV2.java | 6 +- .../models/EdgeNGramTokenizer.java | 6 +- .../models/ElisionTokenFilter.java | 6 +- .../models/KeepTokenFilter.java | 6 +- .../models/KeywordMarkerTokenFilter.java | 6 +- .../models/KeywordTokenizer.java | 6 +- .../models/KeywordTokenizerV2.java | 6 +- .../models/LengthTokenFilter.java | 6 +- .../models/LexicalTokenizer.java | 4 +- .../models/LimitTokenFilter.java | 6 +- .../models/LuceneStandardTokenizer.java | 6 +- .../models/LuceneStandardTokenizerV2.java | 6 +- .../MicrosoftLanguageStemmingTokenizer.java | 6 +- .../models/MicrosoftLanguageTokenizer.java | 6 +- .../models/NGramTokenFilter.java | 6 +- .../models/NGramTokenFilterV2.java | 6 +- .../implementation/models/NGramTokenizer.java | 6 +- .../models/PathHierarchyTokenizerV2.java | 6 +- .../models/PatternCaptureTokenFilter.java | 6 +- .../models/PatternReplaceTokenFilter.java | 6 +- .../models/PatternTokenizer.java | 6 +- .../models/PhoneticTokenFilter.java | 6 +- .../models/ShingleTokenFilter.java | 6 +- .../models/SnowballTokenFilter.java | 6 +- .../models/StemmerOverrideTokenFilter.java | 6 +- .../models/StemmerTokenFilter.java | 6 +- .../models/StopwordsTokenFilter.java | 6 +- .../models/SynonymTokenFilter.java | 6 +- .../implementation/models/TokenFilter.java | 4 +- .../models/TruncateTokenFilter.java | 6 +- .../models/UaxUrlEmailTokenizer.java | 6 +- .../models/UniqueTokenFilter.java | 6 +- .../models/WordDelimiterTokenFilter.java | 6 +- .../models/BM25SimilarityAlgorithm.java | 4 +- .../documents/indexes/models/CharFilter.java | 4 +- .../models/ClassicSimilarityAlgorithm.java | 4 +- .../models/CognitiveServicesAccount.java | 4 +- .../models/CognitiveServicesAccountKey.java | 4 +- .../indexes/models/ConditionalSkill.java | 4 +- .../indexes/models/CustomAnalyzer.java | 4 +- .../models/CustomEntityLookupSkill.java | 4 +- .../indexes/models/CustomNormalizer.java | 4 +- .../models/DataChangeDetectionPolicy.java | 4 +- .../models/DataDeletionDetectionPolicy.java | 4 +- .../DefaultCognitiveServicesAccount.java | 4 +- .../models/DocumentExtractionSkill.java | 4 +- .../models/EntityRecognitionSkill.java | 4 +- .../HighWaterMarkChangeDetectionPolicy.java | 4 +- .../indexes/models/ImageAnalysisSkill.java | 4 +- .../models/KeyPhraseExtractionSkill.java | 4 +- .../models/LanguageDetectionSkill.java | 4 +- .../indexes/models/LexicalAnalyzer.java | 4 +- .../indexes/models/LexicalNormalizer.java | 4 +- .../models/LuceneStandardAnalyzer.java | 4 +- .../indexes/models/MappingCharFilter.java | 4 +- .../documents/indexes/models/MergeSkill.java | 4 +- .../documents/indexes/models/OcrSkill.java | 4 +- .../indexes/models/PatternAnalyzer.java | 4 +- .../models/PatternReplaceCharFilter.java | 4 +- ...rKnowledgeStoreBlobProjectionSelector.java | 36 +++++++++- ...rKnowledgeStoreFileProjectionSelector.java | 37 ++++++++++- ...nowledgeStoreObjectProjectionSelector.java | 37 ++++++++++- ...dexerKnowledgeStoreProjectionSelector.java | 2 +- ...KnowledgeStoreTableProjectionSelector.java | 33 ++++++++++ .../indexes/models/SearchIndexerSkill.java | 4 +- .../indexes/models/SentimentSkill.java | 4 +- .../documents/indexes/models/ShaperSkill.java | 4 +- .../indexes/models/SimilarityAlgorithm.java | 4 +- ...ftDeleteColumnDeletionDetectionPolicy.java | 4 +- .../documents/indexes/models/SplitSkill.java | 4 +- .../SqlIntegratedChangeTrackingPolicy.java | 4 +- .../indexes/models/StopAnalyzer.java | 4 +- .../indexes/models/TextTranslationSkill.java | 4 +- .../documents/indexes/models/WebApiSkill.java | 4 +- .../src/samples/README.md | 2 +- .../azure-search-documents/swagger/README.md | 1 + .../java/SearchServiceCustomizations.java | 65 ++++++++++++++++++- sdk/search/azure-search-perf/pom.xml | 2 +- sdk/search/pom.xml | 2 +- 90 files changed, 354 insertions(+), 277 deletions(-) diff --git a/eng/jacoco-test-coverage/pom.xml b/eng/jacoco-test-coverage/pom.xml index 30e6206124887..dc05de4c42a85 100644 --- a/eng/jacoco-test-coverage/pom.xml +++ b/eng/jacoco-test-coverage/pom.xml @@ -229,7 +229,7 @@ com.azure azure-search-documents - 11.4.0-beta.3 + 11.5.0-beta.1 com.azure diff --git a/eng/versioning/version_client.txt b/eng/versioning/version_client.txt index 6a3a69bc8a973..bb873e06b8029 100644 --- a/eng/versioning/version_client.txt +++ b/eng/versioning/version_client.txt @@ -101,7 +101,7 @@ com.azure:azure-mixedreality-remoterendering;1.0.0;1.1.0-beta.1 com.azure:azure-monitor-opentelemetry-exporter;1.0.0-beta.4;1.0.0-beta.5 com.azure:azure-monitor-query;1.0.0-beta.1;1.0.0-beta.1 com.azure:azure-quantum-jobs;1.0.0-beta.1;1.0.0-beta.2 -com.azure:azure-search-documents;11.3.2;11.4.0-beta.3 +com.azure:azure-search-documents;11.4.0;11.5.0-beta.1 com.azure:azure-search-perf;1.0.0-beta.1;1.0.0-beta.1 com.azure:azure-security-attestation;1.0.0-beta.1;1.0.0-beta.2 com.azure:azure-security-confidentialledger;1.0.0-beta.2;1.0.0-beta.2 diff --git a/sdk/search/azure-search-documents/CHANGELOG.md b/sdk/search/azure-search-documents/CHANGELOG.md index b1a898ec0aea2..2a2de263d8c1e 100644 --- a/sdk/search/azure-search-documents/CHANGELOG.md +++ b/sdk/search/azure-search-documents/CHANGELOG.md @@ -1,6 +1,36 @@ # Release History -## 11.4.0-beta.3 (Unreleased) +## 11.5.0-beta.1 (Unreleased) + +## 11.4.0 (2021-06-08) + +### Features Added + +- Added the ability to configure Knowledge Store in skillsets. +- Added factory method to `SynonymMap` to enable creation from a file. +- Added support for `Edm.GeographyPoint` in `FieldBuilder` when property has type `GeoPoint`. +- Added support for geography based filtering in `SearchFilter` when `GeoPosition`, `GeoPoint`, `GeoLineString`, or + `GeoPolygon` are used as formatting arguments. +- Added new skills `CustomEntityLookupSkill` and `DocumentExtractionSkill` and new skill versions for + `KeyPhraseExtractionSkill` and `LanguageDetectionSkill`. +- Added support for the ADLS Gen 2 Indexer data source type. +- Added skillset counts to `SearchServiceCounters`. +- Added additional log messages to `SearchIndexingBufferedSender` and `SearchIndexingBufferedAsyncSender`. + +### Breaking Changes + +- Removed support for service version `2020-06-30-Preview`. Default version is now `2020-06-30`. +- Removed Semantic Search capability to `SearchClient` and `SearchAsyncClient`. +- Removed support for Normalizers in `SearchField` and `SearchIndex` with `CustomNormalizer` and `LexicalNormalizer`. + +### Dependency Updates + +- Updated `azure-core` from `1.16.0` to `1.17.0`. +- Updated `azure-core-http-netty` from `1.9.2` to `1.10.0`. +- Updated `azure-core-serializer-json-jackson` from `1.2.3` to `1.2.4`. +- Updated Jackson from `2.12.2` to `2.12.3`. +- Updated Reactor from `3.4.5` to `3.4.6`. +- Updated Reactor Netty from `1.0.6` to `1.0.7`. ## 11.3.2 (2021-05-11) diff --git a/sdk/search/azure-search-documents/README.md b/sdk/search/azure-search-documents/README.md index c9a00db7767b3..0f8d0406024d1 100644 --- a/sdk/search/azure-search-documents/README.md +++ b/sdk/search/azure-search-documents/README.md @@ -38,7 +38,7 @@ Use the Azure Cognitive Search client library to: com.azure azure-search-documents - 11.3.2 + 11.4.0 ``` [//]: # ({x-version-update-end}) diff --git a/sdk/search/azure-search-documents/pom.xml b/sdk/search/azure-search-documents/pom.xml index d029c6bfaf312..be15bfb21d475 100644 --- a/sdk/search/azure-search-documents/pom.xml +++ b/sdk/search/azure-search-documents/pom.xml @@ -16,7 +16,7 @@ com.azure azure-search-documents - 11.4.0-beta.3 + 11.5.0-beta.1 jar diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/AsciiFoldingTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/AsciiFoldingTokenFilter.java index 6a1e2a436e681..d26982874dd59 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/AsciiFoldingTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/AsciiFoldingTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -18,11 +17,10 @@ * "Basic Latin" Unicode block) into their ASCII equivalents, if such equivalents exist. This token filter is * implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.AsciiFoldingTokenFilter") -@JsonFlatten @Fluent -public class AsciiFoldingTokenFilter extends TokenFilter { +public final class AsciiFoldingTokenFilter extends TokenFilter { /* * A value indicating whether the original token will be kept. Default is * false. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/CjkBigramTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/CjkBigramTokenFilter.java index 0d19feedec7b4..c3fd45a270679 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/CjkBigramTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/CjkBigramTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.CjkBigramTokenFilterScripts; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -19,11 +18,10 @@ * Forms bigrams of CJK terms that are generated from the standard tokenizer. This token filter is implemented using * Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.CjkBigramTokenFilter") -@JsonFlatten @Fluent -public class CjkBigramTokenFilter extends TokenFilter { +public final class CjkBigramTokenFilter extends TokenFilter { /* * The scripts to ignore. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ClassicTokenizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ClassicTokenizer.java index 270ad44a8b8c5..23f74953a7fcf 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ClassicTokenizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ClassicTokenizer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -17,11 +16,10 @@ * Grammar-based tokenizer that is suitable for processing most European-language documents. This tokenizer is * implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.ClassicTokenizer") -@JsonFlatten @Fluent -public class ClassicTokenizer extends LexicalTokenizer { +public final class ClassicTokenizer extends LexicalTokenizer { /* * The maximum token length. Default is 255. Tokens longer than the maximum * length are split. The maximum token length that can be used is 300 diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/CommonGramTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/CommonGramTokenFilter.java index 700dc0deffb72..5875af42e3453 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/CommonGramTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/CommonGramTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -18,11 +17,10 @@ * Construct bigrams for frequently occurring terms while indexing. Single terms are still indexed too, with bigrams * overlaid. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.CommonGramTokenFilter") -@JsonFlatten @Fluent -public class CommonGramTokenFilter extends TokenFilter { +public final class CommonGramTokenFilter extends TokenFilter { /* * The set of common words. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/DictionaryDecompounderTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/DictionaryDecompounderTokenFilter.java index 1a623afd3a405..647c08f50df58 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/DictionaryDecompounderTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/DictionaryDecompounderTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -15,11 +14,10 @@ import java.util.List; /** Decomposes compound words found in many Germanic languages. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.DictionaryDecompounderTokenFilter") -@JsonFlatten @Fluent -public class DictionaryDecompounderTokenFilter extends TokenFilter { +public final class DictionaryDecompounderTokenFilter extends TokenFilter { /* * The list of words to match against. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenFilter.java index bab0bc04e5da1..d01adaed1d9a7 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.EdgeNGramTokenFilterSide; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -18,11 +17,10 @@ * Generates n-grams of the given size(s) starting from the front or the back of an input token. This token filter is * implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.EdgeNGramTokenFilter") -@JsonFlatten @Fluent -public class EdgeNGramTokenFilter extends TokenFilter { +public final class EdgeNGramTokenFilter extends TokenFilter { /* * The minimum n-gram length. Default is 1. Must be less than the value of * maxGram. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenFilterV2.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenFilterV2.java index 4ed4c22939ef5..79b303fd22167 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenFilterV2.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenFilterV2.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.EdgeNGramTokenFilterSide; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -18,11 +17,10 @@ * Generates n-grams of the given size(s) starting from the front or the back of an input token. This token filter is * implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.EdgeNGramTokenFilterV2") -@JsonFlatten @Fluent -public class EdgeNGramTokenFilterV2 extends TokenFilter { +public final class EdgeNGramTokenFilterV2 extends TokenFilter { /* * The minimum n-gram length. Default is 1. Maximum is 300. Must be less * than the value of maxGram. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenizer.java index 896284a9f1931..8cb00531daffe 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/EdgeNGramTokenizer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.TokenCharacterKind; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -19,11 +18,10 @@ * Tokenizes the input from an edge into n-grams of the given size(s). This tokenizer is implemented using Apache * Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.EdgeNGramTokenizer") -@JsonFlatten @Fluent -public class EdgeNGramTokenizer extends LexicalTokenizer { +public final class EdgeNGramTokenizer extends LexicalTokenizer { /* * The minimum n-gram length. Default is 1. Maximum is 300. Must be less * than the value of maxGram. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ElisionTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ElisionTokenFilter.java index 8510fcceea4f5..e12bcd6bef0cb 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ElisionTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ElisionTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -18,11 +17,10 @@ * Removes elisions. For example, "l'avion" (the plane) will be converted to "avion" (plane). This token filter is * implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.ElisionTokenFilter") -@JsonFlatten @Fluent -public class ElisionTokenFilter extends TokenFilter { +public final class ElisionTokenFilter extends TokenFilter { /* * The set of articles to remove. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeepTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeepTokenFilter.java index 0247fc467e325..b988cf787ae6c 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeepTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeepTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -18,11 +17,10 @@ * A token filter that only keeps tokens with text contained in a specified list of words. This token filter is * implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.KeepTokenFilter") -@JsonFlatten @Fluent -public class KeepTokenFilter extends TokenFilter { +public final class KeepTokenFilter extends TokenFilter { /* * The list of words to keep. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordMarkerTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordMarkerTokenFilter.java index 9e73147db2070..94554ee724c30 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordMarkerTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordMarkerTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -15,11 +14,10 @@ import java.util.List; /** Marks terms as keywords. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.KeywordMarkerTokenFilter") -@JsonFlatten @Fluent -public class KeywordMarkerTokenFilter extends TokenFilter { +public final class KeywordMarkerTokenFilter extends TokenFilter { /* * A list of words to mark as keywords. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordTokenizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordTokenizer.java index 94094f307e2dd..d888e84161bf0 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordTokenizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordTokenizer.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Emits the entire input as a single token. This tokenizer is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.KeywordTokenizer") -@JsonFlatten @Fluent -public class KeywordTokenizer extends LexicalTokenizer { +public final class KeywordTokenizer extends LexicalTokenizer { /* * The read buffer size in bytes. Default is 256. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordTokenizerV2.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordTokenizerV2.java index ca2936b246510..7810e2a6a30bc 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordTokenizerV2.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/KeywordTokenizerV2.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Emits the entire input as a single token. This tokenizer is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.KeywordTokenizerV2") -@JsonFlatten @Fluent -public class KeywordTokenizerV2 extends LexicalTokenizer { +public final class KeywordTokenizerV2 extends LexicalTokenizer { /* * The maximum token length. Default is 256. Tokens longer than the maximum * length are split. The maximum token length that can be used is 300 diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LengthTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LengthTokenFilter.java index 81e66a50ffe13..315abd86c42dc 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LengthTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LengthTokenFilter.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Removes words that are too long or too short. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.LengthTokenFilter") -@JsonFlatten @Fluent -public class LengthTokenFilter extends TokenFilter { +public final class LengthTokenFilter extends TokenFilter { /* * The minimum length in characters. Default is 0. Maximum is 300. Must be * less than the value of max. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LexicalTokenizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LexicalTokenizer.java index 8e1f3de664655..c623c699ec6de 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LexicalTokenizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LexicalTokenizer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSubTypes; @@ -18,7 +17,7 @@ @JsonTypeInfo( use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, - property = "@odata\\.type", + property = "@odata.type", defaultImpl = LexicalTokenizer.class) @JsonTypeName("LexicalTokenizer") @JsonSubTypes({ @@ -41,7 +40,6 @@ @JsonSubTypes.Type(name = "#Microsoft.Azure.Search.StandardTokenizerV2", value = LuceneStandardTokenizerV2.class), @JsonSubTypes.Type(name = "#Microsoft.Azure.Search.UaxUrlEmailTokenizer", value = UaxUrlEmailTokenizer.class) }) -@JsonFlatten @Fluent public class LexicalTokenizer { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LimitTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LimitTokenFilter.java index 0f1885f8cb67e..9c5008dc04f2f 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LimitTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LimitTokenFilter.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Limits the number of tokens while indexing. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.LimitTokenFilter") -@JsonFlatten @Fluent -public class LimitTokenFilter extends TokenFilter { +public final class LimitTokenFilter extends TokenFilter { /* * The maximum number of tokens to produce. Default is 1. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LuceneStandardTokenizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LuceneStandardTokenizer.java index 38f4b9cb618ad..1fcfca6825a98 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LuceneStandardTokenizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LuceneStandardTokenizer.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Breaks text following the Unicode Text Segmentation rules. This tokenizer is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.StandardTokenizer") -@JsonFlatten @Fluent -public class LuceneStandardTokenizer extends LexicalTokenizer { +public final class LuceneStandardTokenizer extends LexicalTokenizer { /* * The maximum token length. Default is 255. Tokens longer than the maximum * length are split. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LuceneStandardTokenizerV2.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LuceneStandardTokenizerV2.java index 858f53e190a29..f0e66e5498269 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LuceneStandardTokenizerV2.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/LuceneStandardTokenizerV2.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Breaks text following the Unicode Text Segmentation rules. This tokenizer is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.StandardTokenizerV2") -@JsonFlatten @Fluent -public class LuceneStandardTokenizerV2 extends LexicalTokenizer { +public final class LuceneStandardTokenizerV2 extends LexicalTokenizer { /* * The maximum token length. Default is 255. Tokens longer than the maximum * length are split. The maximum token length that can be used is 300 diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/MicrosoftLanguageStemmingTokenizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/MicrosoftLanguageStemmingTokenizer.java index 850a2f8775ab6..c9ad305d99ea7 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/MicrosoftLanguageStemmingTokenizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/MicrosoftLanguageStemmingTokenizer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.MicrosoftStemmingTokenizerLanguage; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -15,11 +14,10 @@ import com.fasterxml.jackson.annotation.JsonTypeName; /** Divides text using language-specific rules and reduces words to their base forms. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.MicrosoftLanguageStemmingTokenizer") -@JsonFlatten @Fluent -public class MicrosoftLanguageStemmingTokenizer extends LexicalTokenizer { +public final class MicrosoftLanguageStemmingTokenizer extends LexicalTokenizer { /* * The maximum token length. Tokens longer than the maximum length are * split. Maximum token length that can be used is 300 characters. Tokens diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/MicrosoftLanguageTokenizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/MicrosoftLanguageTokenizer.java index 5345914df5a22..663e63c809eb8 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/MicrosoftLanguageTokenizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/MicrosoftLanguageTokenizer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.MicrosoftTokenizerLanguage; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -15,11 +14,10 @@ import com.fasterxml.jackson.annotation.JsonTypeName; /** Divides text using language-specific rules. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.MicrosoftLanguageTokenizer") -@JsonFlatten @Fluent -public class MicrosoftLanguageTokenizer extends LexicalTokenizer { +public final class MicrosoftLanguageTokenizer extends LexicalTokenizer { /* * The maximum token length. Tokens longer than the maximum length are * split. Maximum token length that can be used is 300 characters. Tokens diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenFilter.java index af6e2ad9ee5c3..db5f5b28f2541 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenFilter.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Generates n-grams of the given size(s). This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.NGramTokenFilter") -@JsonFlatten @Fluent -public class NGramTokenFilter extends TokenFilter { +public final class NGramTokenFilter extends TokenFilter { /* * The minimum n-gram length. Default is 1. Must be less than the value of * maxGram. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenFilterV2.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenFilterV2.java index 5ca3b99d10c01..4eabb7557d0db 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenFilterV2.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenFilterV2.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Generates n-grams of the given size(s). This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.NGramTokenFilterV2") -@JsonFlatten @Fluent -public class NGramTokenFilterV2 extends TokenFilter { +public final class NGramTokenFilterV2 extends TokenFilter { /* * The minimum n-gram length. Default is 1. Maximum is 300. Must be less * than the value of maxGram. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenizer.java index 01d9d216f4a23..ee73e49dd88b1 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/NGramTokenizer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.TokenCharacterKind; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -16,11 +15,10 @@ import java.util.List; /** Tokenizes the input into n-grams of the given size(s). This tokenizer is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.NGramTokenizer") -@JsonFlatten @Fluent -public class NGramTokenizer extends LexicalTokenizer { +public final class NGramTokenizer extends LexicalTokenizer { /* * The minimum n-gram length. Default is 1. Maximum is 300. Must be less * than the value of maxGram. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PathHierarchyTokenizerV2.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PathHierarchyTokenizerV2.java index e7aeca159d2b5..85c1b27d6997a 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PathHierarchyTokenizerV2.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PathHierarchyTokenizerV2.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Tokenizer for path-like hierarchies. This tokenizer is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.PathHierarchyTokenizerV2") -@JsonFlatten @Fluent -public class PathHierarchyTokenizerV2 extends LexicalTokenizer { +public final class PathHierarchyTokenizerV2 extends LexicalTokenizer { /* * The delimiter character to use. Default is "/". */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternCaptureTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternCaptureTokenFilter.java index 69e9648b0a6ce..dee8d5657942d 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternCaptureTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternCaptureTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -18,11 +17,10 @@ * Uses Java regexes to emit multiple tokens - one for each capture group in one or more patterns. This token filter is * implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.PatternCaptureTokenFilter") -@JsonFlatten @Fluent -public class PatternCaptureTokenFilter extends TokenFilter { +public final class PatternCaptureTokenFilter extends TokenFilter { /* * A list of patterns to match against each token. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternReplaceTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternReplaceTokenFilter.java index cc63bca32eec0..483377527c052 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternReplaceTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternReplaceTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -19,11 +18,10 @@ * "aa bb aa bb", pattern "(aa)\s+(bb)", and replacement "$1#$2", the result would be "aa#bb aa#bb". This token filter * is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.PatternReplaceTokenFilter") -@JsonFlatten @Fluent -public class PatternReplaceTokenFilter extends TokenFilter { +public final class PatternReplaceTokenFilter extends TokenFilter { /* * A regular expression pattern. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternTokenizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternTokenizer.java index 9f3cf38ab50a8..facb32fd2a892 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternTokenizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PatternTokenizer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.RegexFlags; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -18,11 +17,10 @@ * Tokenizer that uses regex pattern matching to construct distinct tokens. This tokenizer is implemented using Apache * Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.PatternTokenizer") -@JsonFlatten @Fluent -public class PatternTokenizer extends LexicalTokenizer { +public final class PatternTokenizer extends LexicalTokenizer { /* * A regular expression pattern to match token separators. Default is an * expression that matches one or more non-word characters. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PhoneticTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PhoneticTokenFilter.java index 2f2b67e708de6..0cc0a41f4cf81 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PhoneticTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/PhoneticTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.PhoneticEncoder; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -15,11 +14,10 @@ import com.fasterxml.jackson.annotation.JsonTypeName; /** Create tokens for phonetic matches. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.PhoneticTokenFilter") -@JsonFlatten @Fluent -public class PhoneticTokenFilter extends TokenFilter { +public final class PhoneticTokenFilter extends TokenFilter { /* * The phonetic encoder to use. Default is "metaphone". */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ShingleTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ShingleTokenFilter.java index 113fbbf715499..fc84724128620 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ShingleTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/ShingleTokenFilter.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Creates combinations of tokens as a single token. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.ShingleTokenFilter") -@JsonFlatten @Fluent -public class ShingleTokenFilter extends TokenFilter { +public final class ShingleTokenFilter extends TokenFilter { /* * The maximum shingle size. Default and minimum value is 2. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/SnowballTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/SnowballTokenFilter.java index e7c8a450023f0..f7b487b729c45 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/SnowballTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/SnowballTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.SnowballTokenFilterLanguage; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -17,11 +16,10 @@ /** * A filter that stems words using a Snowball-generated stemmer. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.SnowballTokenFilter") -@JsonFlatten @Fluent -public class SnowballTokenFilter extends TokenFilter { +public final class SnowballTokenFilter extends TokenFilter { /* * The language to use. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StemmerOverrideTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StemmerOverrideTokenFilter.java index 8877c8d665400..ba033dc1b0253 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StemmerOverrideTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StemmerOverrideTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -19,11 +18,10 @@ * terms will be marked as keywords so that they will not be stemmed with stemmers down the chain. Must be placed before * any stemming filters. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.StemmerOverrideTokenFilter") -@JsonFlatten @Fluent -public class StemmerOverrideTokenFilter extends TokenFilter { +public final class StemmerOverrideTokenFilter extends TokenFilter { /* * A list of stemming rules in the following format: "word => stem", for * example: "ran => run". diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StemmerTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StemmerTokenFilter.java index bae2b83de2e9a..2aa4bb827b03f 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StemmerTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StemmerTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.StemmerTokenFilterLanguage; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -15,11 +14,10 @@ import com.fasterxml.jackson.annotation.JsonTypeName; /** Language specific stemming filter. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.StemmerTokenFilter") -@JsonFlatten @Fluent -public class StemmerTokenFilter extends TokenFilter { +public final class StemmerTokenFilter extends TokenFilter { /* * The language to use. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StopwordsTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StopwordsTokenFilter.java index 9fad42176f929..f1ad3ac11e985 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StopwordsTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/StopwordsTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.search.documents.indexes.models.StopwordsList; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; @@ -16,11 +15,10 @@ import java.util.List; /** Removes stop words from a token stream. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.StopwordsTokenFilter") -@JsonFlatten @Fluent -public class StopwordsTokenFilter extends TokenFilter { +public final class StopwordsTokenFilter extends TokenFilter { /* * The list of stopwords. This property and the stopwords list property * cannot both be set. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/SynonymTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/SynonymTokenFilter.java index cee85167d70a2..067426e17a97d 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/SynonymTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/SynonymTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -15,11 +14,10 @@ import java.util.List; /** Matches single or multi-word synonyms in a token stream. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.SynonymTokenFilter") -@JsonFlatten @Fluent -public class SynonymTokenFilter extends TokenFilter { +public final class SynonymTokenFilter extends TokenFilter { /* * A list of synonyms in following one of two formats: 1. incredible, * unbelievable, fabulous => amazing - all terms on the left side of => diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/TokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/TokenFilter.java index 6a5629798800f..d5ac80737935e 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/TokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/TokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSubTypes; @@ -18,7 +17,7 @@ @JsonTypeInfo( use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, - property = "@odata\\.type", + property = "@odata.type", defaultImpl = TokenFilter.class) @JsonTypeName("TokenFilter") @JsonSubTypes({ @@ -60,7 +59,6 @@ name = "#Microsoft.Azure.Search.WordDelimiterTokenFilter", value = WordDelimiterTokenFilter.class) }) -@JsonFlatten @Fluent public class TokenFilter { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/TruncateTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/TruncateTokenFilter.java index 03989131417ce..cda90fd713173 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/TruncateTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/TruncateTokenFilter.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Truncates the terms to a specific length. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.TruncateTokenFilter") -@JsonFlatten @Fluent -public class TruncateTokenFilter extends TokenFilter { +public final class TruncateTokenFilter extends TokenFilter { /* * The length at which terms will be truncated. Default and maximum is 300. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/UaxUrlEmailTokenizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/UaxUrlEmailTokenizer.java index d29c07afb3a3f..8754c0d38e620 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/UaxUrlEmailTokenizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/UaxUrlEmailTokenizer.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Tokenizes urls and emails as one token. This tokenizer is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.UaxUrlEmailTokenizer") -@JsonFlatten @Fluent -public class UaxUrlEmailTokenizer extends LexicalTokenizer { +public final class UaxUrlEmailTokenizer extends LexicalTokenizer { /* * The maximum token length. Default is 255. Tokens longer than the maximum * length are split. The maximum token length that can be used is 300 diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/UniqueTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/UniqueTokenFilter.java index 7451661df0773..2b7985ee2699a 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/UniqueTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/UniqueTokenFilter.java @@ -7,18 +7,16 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Filters out tokens with same text as the previous token. This token filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.UniqueTokenFilter") -@JsonFlatten @Fluent -public class UniqueTokenFilter extends TokenFilter { +public final class UniqueTokenFilter extends TokenFilter { /* * A value indicating whether to remove duplicates only at the same * position. Default is false. diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/WordDelimiterTokenFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/WordDelimiterTokenFilter.java index 59624d9b8d321..6d11d33ee6872 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/WordDelimiterTokenFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/implementation/models/WordDelimiterTokenFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.implementation.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -18,11 +17,10 @@ * Splits words into subwords and performs optional transformations on subword groups. This token filter is implemented * using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.WordDelimiterTokenFilter") -@JsonFlatten @Fluent -public class WordDelimiterTokenFilter extends TokenFilter { +public final class WordDelimiterTokenFilter extends TokenFilter { /* * A value indicating whether to generate part words. If set, causes parts * of words to be generated; for example "AzureSearch" becomes "Azure" diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/BM25SimilarityAlgorithm.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/BM25SimilarityAlgorithm.java index 50db424df7b85..95941ba390973 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/BM25SimilarityAlgorithm.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/BM25SimilarityAlgorithm.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -17,9 +16,8 @@ * normalization (controlled by the 'b' parameter) as well as term frequency saturation (controlled by the 'k1' * parameter). */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.BM25Similarity") -@JsonFlatten @Fluent public final class BM25SimilarityAlgorithm extends SimilarityAlgorithm { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CharFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CharFilter.java index 4271dd1f2f934..5f6f0535cb6ec 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CharFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CharFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSubTypes; @@ -18,7 +17,7 @@ @JsonTypeInfo( use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, - property = "@odata\\.type", + property = "@odata.type", defaultImpl = CharFilter.class) @JsonTypeName("CharFilter") @JsonSubTypes({ @@ -27,7 +26,6 @@ name = "#Microsoft.Azure.Search.PatternReplaceCharFilter", value = PatternReplaceCharFilter.class) }) -@JsonFlatten @Fluent public abstract class CharFilter { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ClassicSimilarityAlgorithm.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ClassicSimilarityAlgorithm.java index 04e1b468e5e2e..4ce9e25603279 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ClassicSimilarityAlgorithm.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ClassicSimilarityAlgorithm.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Immutable; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -16,8 +15,7 @@ * introduces static document length normalization as well as coordinating factors that penalize documents that only * partially match the searched queries. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.ClassicSimilarity") -@JsonFlatten @Immutable public final class ClassicSimilarityAlgorithm extends SimilarityAlgorithm { } diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CognitiveServicesAccount.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CognitiveServicesAccount.java index d09ae490e40df..305dbcb628e43 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CognitiveServicesAccount.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CognitiveServicesAccount.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSubTypes; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -17,7 +16,7 @@ @JsonTypeInfo( use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, - property = "@odata\\.type", + property = "@odata.type", defaultImpl = CognitiveServicesAccount.class) @JsonTypeName("CognitiveServicesAccount") @JsonSubTypes({ @@ -28,7 +27,6 @@ name = "#Microsoft.Azure.Search.CognitiveServicesByKey", value = CognitiveServicesAccountKey.class) }) -@JsonFlatten @Fluent public abstract class CognitiveServicesAccount { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CognitiveServicesAccountKey.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CognitiveServicesAccountKey.java index bbe9230a0843e..89d6d0df47b7a 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CognitiveServicesAccountKey.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CognitiveServicesAccountKey.java @@ -7,16 +7,14 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** A cognitive service resource provisioned with a key that is attached to a skillset. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.CognitiveServicesByKey") -@JsonFlatten @Fluent public final class CognitiveServicesAccountKey extends CognitiveServicesAccount { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ConditionalSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ConditionalSkill.java index ab722e61c1972..bc685fba465ee 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ConditionalSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ConditionalSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Immutable; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -15,9 +14,8 @@ import java.util.List; /** A skill that enables scenarios that require a Boolean operation to determine the data to assign to an output. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Util.ConditionalSkill") -@JsonFlatten @Immutable public final class ConditionalSkill extends SearchIndexerSkill { /** diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomAnalyzer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomAnalyzer.java index 1390b72321621..961cd9757bfe9 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomAnalyzer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomAnalyzer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSetter; @@ -20,9 +19,8 @@ * configuration consisting of a single predefined tokenizer and one or more filters. The tokenizer is responsible for * breaking text into tokens, and the filters for modifying tokens emitted by the tokenizer. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.CustomAnalyzer") -@JsonFlatten @Fluent public final class CustomAnalyzer extends LexicalAnalyzer { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomEntityLookupSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomEntityLookupSkill.java index d7ac1c994f6f1..58b778f91847b 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomEntityLookupSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomEntityLookupSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSetter; @@ -16,9 +15,8 @@ import java.util.List; /** A skill looks for text from a custom, user-defined list of words and phrases. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Text.CustomEntityLookupSkill") -@JsonFlatten @Fluent public final class CustomEntityLookupSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomNormalizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomNormalizer.java index ccf577f8adcbb..b7e73f7a09786 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomNormalizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/CustomNormalizer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSetter; @@ -20,9 +19,8 @@ * strict matching. This is a user-defined configuration consisting of at least one or more filters, which modify the * token that is stored. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.CustomNormalizer") -@JsonFlatten @Fluent public final class CustomNormalizer extends LexicalNormalizer { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DataChangeDetectionPolicy.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DataChangeDetectionPolicy.java index 5151f6ac4099b..94ad111461edb 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DataChangeDetectionPolicy.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DataChangeDetectionPolicy.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Immutable; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonSubTypes; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -16,7 +15,7 @@ @JsonTypeInfo( use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, - property = "@odata\\.type", + property = "@odata.type", defaultImpl = DataChangeDetectionPolicy.class) @JsonTypeName("DataChangeDetectionPolicy") @JsonSubTypes({ @@ -27,6 +26,5 @@ name = "#Microsoft.Azure.Search.SqlIntegratedChangeTrackingPolicy", value = SqlIntegratedChangeTrackingPolicy.class) }) -@JsonFlatten @Immutable public abstract class DataChangeDetectionPolicy { } diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DataDeletionDetectionPolicy.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DataDeletionDetectionPolicy.java index 64b07de122087..99e364bc54fcf 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DataDeletionDetectionPolicy.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DataDeletionDetectionPolicy.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Immutable; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonSubTypes; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -16,7 +15,7 @@ @JsonTypeInfo( use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, - property = "@odata\\.type", + property = "@odata.type", defaultImpl = DataDeletionDetectionPolicy.class) @JsonTypeName("DataDeletionDetectionPolicy") @JsonSubTypes({ @@ -24,6 +23,5 @@ name = "#Microsoft.Azure.Search.SoftDeleteColumnDeletionDetectionPolicy", value = SoftDeleteColumnDeletionDetectionPolicy.class) }) -@JsonFlatten @Immutable public abstract class DataDeletionDetectionPolicy { } diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DefaultCognitiveServicesAccount.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DefaultCognitiveServicesAccount.java index 2dc6d6e089ebb..98d77fef234a9 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DefaultCognitiveServicesAccount.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DefaultCognitiveServicesAccount.java @@ -7,13 +7,11 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Immutable; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** An empty object that represents the default cognitive service resource for a skillset. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.DefaultCognitiveServices") -@JsonFlatten @Immutable public final class DefaultCognitiveServicesAccount extends CognitiveServicesAccount { } diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DocumentExtractionSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DocumentExtractionSkill.java index 8fd05ef6f0cb9..ba20bcbb9ff79 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DocumentExtractionSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/DocumentExtractionSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -16,9 +15,8 @@ import java.util.Map; /** A skill that extracts content from a file within the enrichment pipeline. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Util.DocumentExtractionSkill") -@JsonFlatten @Fluent public final class DocumentExtractionSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/EntityRecognitionSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/EntityRecognitionSkill.java index 95385b2332cd0..1a83c4a0d4ba4 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/EntityRecognitionSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/EntityRecognitionSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSetter; @@ -16,9 +15,8 @@ import java.util.List; /** Text analytics entity recognition. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Text.EntityRecognitionSkill") -@JsonFlatten @Fluent public final class EntityRecognitionSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/HighWaterMarkChangeDetectionPolicy.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/HighWaterMarkChangeDetectionPolicy.java index fc9390e83fb5c..f028fa3cc48df 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/HighWaterMarkChangeDetectionPolicy.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/HighWaterMarkChangeDetectionPolicy.java @@ -7,16 +7,14 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** Defines a data change detection policy that captures changes based on the value of a high water mark column. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.HighWaterMarkChangeDetectionPolicy") -@JsonFlatten @Fluent public final class HighWaterMarkChangeDetectionPolicy extends DataChangeDetectionPolicy { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ImageAnalysisSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ImageAnalysisSkill.java index 5060966aa5a86..bd235e0e39833 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ImageAnalysisSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ImageAnalysisSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSetter; @@ -16,9 +15,8 @@ import java.util.List; /** A skill that analyzes image files. It extracts a rich set of visual features based on the image content. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Vision.ImageAnalysisSkill") -@JsonFlatten @Fluent public final class ImageAnalysisSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/KeyPhraseExtractionSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/KeyPhraseExtractionSkill.java index 0fe25e194355a..581c2b3d1b24a 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/KeyPhraseExtractionSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/KeyPhraseExtractionSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -15,9 +14,8 @@ import java.util.List; /** A skill that uses text analytics for key phrase extraction. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Text.KeyPhraseExtractionSkill") -@JsonFlatten @Fluent public final class KeyPhraseExtractionSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LanguageDetectionSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LanguageDetectionSkill.java index 6ed2891ebe781..909d2a408da45 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LanguageDetectionSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LanguageDetectionSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -18,9 +17,8 @@ * A skill that detects the language of input text and reports a single language code for every document submitted on * the request. The language code is paired with a score indicating the confidence of the analysis. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Text.LanguageDetectionSkill") -@JsonFlatten @Fluent public final class LanguageDetectionSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LexicalAnalyzer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LexicalAnalyzer.java index f317cd8bcafa9..bd9229d71c30d 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LexicalAnalyzer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LexicalAnalyzer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSubTypes; @@ -18,7 +17,7 @@ @JsonTypeInfo( use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, - property = "@odata\\.type", + property = "@odata.type", defaultImpl = LexicalAnalyzer.class) @JsonTypeName("LexicalAnalyzer") @JsonSubTypes({ @@ -27,7 +26,6 @@ @JsonSubTypes.Type(name = "#Microsoft.Azure.Search.StandardAnalyzer", value = LuceneStandardAnalyzer.class), @JsonSubTypes.Type(name = "#Microsoft.Azure.Search.StopAnalyzer", value = StopAnalyzer.class) }) -@JsonFlatten @Fluent public abstract class LexicalAnalyzer { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LexicalNormalizer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LexicalNormalizer.java index 8d374823aa96b..80f25e20ea0b4 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LexicalNormalizer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LexicalNormalizer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSubTypes; @@ -18,11 +17,10 @@ @JsonTypeInfo( use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, - property = "@odata\\.type", + property = "@odata.type", defaultImpl = LexicalNormalizer.class) @JsonTypeName("LexicalNormalizer") @JsonSubTypes({@JsonSubTypes.Type(name = "#Microsoft.Azure.Search.CustomNormalizer", value = CustomNormalizer.class)}) -@JsonFlatten @Fluent public class LexicalNormalizer { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LuceneStandardAnalyzer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LuceneStandardAnalyzer.java index 337f9733a3647..72481a42f605b 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LuceneStandardAnalyzer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/LuceneStandardAnalyzer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSetter; @@ -16,9 +15,8 @@ import java.util.List; /** Standard Apache Lucene analyzer; Composed of the standard tokenizer, lowercase filter and stop filter. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.StandardAnalyzer") -@JsonFlatten @Fluent public final class LuceneStandardAnalyzer extends LexicalAnalyzer { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/MappingCharFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/MappingCharFilter.java index 969be6177b879..ecee396da61de 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/MappingCharFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/MappingCharFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -19,9 +18,8 @@ * matching at a given point wins). Replacement is allowed to be the empty string. This character filter is implemented * using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.MappingCharFilter") -@JsonFlatten @Fluent public final class MappingCharFilter extends CharFilter { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/MergeSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/MergeSkill.java index be1f3354d65ea..dadb01a3d8b54 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/MergeSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/MergeSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -18,9 +17,8 @@ * A skill for merging two or more strings into a single unified string, with an optional user-defined delimiter * separating each component part. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Text.MergeSkill") -@JsonFlatten @Fluent public final class MergeSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/OcrSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/OcrSkill.java index daa872f9810e4..52680bbb033bd 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/OcrSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/OcrSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -15,9 +14,8 @@ import java.util.List; /** A skill that extracts text from image files. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Vision.OcrSkill") -@JsonFlatten @Fluent public final class OcrSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/PatternAnalyzer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/PatternAnalyzer.java index 556aec57fae97..33a7320c87eaa 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/PatternAnalyzer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/PatternAnalyzer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSetter; @@ -20,9 +19,8 @@ * Flexibly separates text into terms via a regular expression pattern. This analyzer is implemented using Apache * Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.PatternAnalyzer") -@JsonFlatten @Fluent public final class PatternAnalyzer extends LexicalAnalyzer { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/PatternReplaceCharFilter.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/PatternReplaceCharFilter.java index 003b0fe72fb48..7ca088e2e3473 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/PatternReplaceCharFilter.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/PatternReplaceCharFilter.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -19,9 +18,8 @@ * "aa bb aa bb", pattern "(aa)\s+(bb)", and replacement "$1#$2", the result would be "aa#bb aa#bb". This character * filter is implemented using Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.PatternReplaceCharFilter") -@JsonFlatten @Fluent public final class PatternReplaceCharFilter extends CharFilter { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreBlobProjectionSelector.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreBlobProjectionSelector.java index 7a214819a2310..31c96012cef16 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreBlobProjectionSelector.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreBlobProjectionSelector.java @@ -10,9 +10,12 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + /** Abstract class to share properties between concrete selectors. */ @Fluent -public class SearchIndexerKnowledgeStoreBlobProjectionSelector extends SearchIndexerKnowledgeStoreProjectionSelector { +public abstract class SearchIndexerKnowledgeStoreBlobProjectionSelector + extends SearchIndexerKnowledgeStoreProjectionSelector { /* * Blob container to store projections in. */ @@ -38,4 +41,35 @@ public SearchIndexerKnowledgeStoreBlobProjectionSelector( public String getStorageContainer() { return this.storageContainer; } + + @Override + public SearchIndexerKnowledgeStoreBlobProjectionSelector setReferenceKeyName(String referenceKeyName) { + super.setReferenceKeyName(referenceKeyName); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreBlobProjectionSelector setGeneratedKeyName(String generatedKeyName) { + super.setGeneratedKeyName(generatedKeyName); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreBlobProjectionSelector setSource(String source) { + super.setSource(source); + + return this; + } + + @Override + public SearchIndexerKnowledgeStoreBlobProjectionSelector setSourceContext(String sourceContext) { + super.setSourceContext(sourceContext); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreBlobProjectionSelector setInputs(List inputs) { + super.setInputs(inputs); + return this; + } } diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreFileProjectionSelector.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreFileProjectionSelector.java index 83b3b047dc524..9155139c03354 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreFileProjectionSelector.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreFileProjectionSelector.java @@ -6,12 +6,14 @@ package com.azure.search.documents.indexes.models; -import com.azure.core.annotation.Immutable; +import com.azure.core.annotation.Fluent; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + /** Projection definition for what data to store in Azure Files. */ -@Immutable +@Fluent public final class SearchIndexerKnowledgeStoreFileProjectionSelector extends SearchIndexerKnowledgeStoreBlobProjectionSelector { /** @@ -24,4 +26,35 @@ public SearchIndexerKnowledgeStoreFileProjectionSelector( @JsonProperty(value = "storageContainer", required = true) String storageContainer) { super(storageContainer); } + + @Override + public SearchIndexerKnowledgeStoreFileProjectionSelector setReferenceKeyName(String referenceKeyName) { + super.setReferenceKeyName(referenceKeyName); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreFileProjectionSelector setGeneratedKeyName(String generatedKeyName) { + super.setGeneratedKeyName(generatedKeyName); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreFileProjectionSelector setSource(String source) { + super.setSource(source); + + return this; + } + + @Override + public SearchIndexerKnowledgeStoreFileProjectionSelector setSourceContext(String sourceContext) { + super.setSourceContext(sourceContext); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreFileProjectionSelector setInputs(List inputs) { + super.setInputs(inputs); + return this; + } } diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreObjectProjectionSelector.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreObjectProjectionSelector.java index fcf4653ba14a8..85fe045ba65c1 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreObjectProjectionSelector.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreObjectProjectionSelector.java @@ -6,12 +6,14 @@ package com.azure.search.documents.indexes.models; -import com.azure.core.annotation.Immutable; +import com.azure.core.annotation.Fluent; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + /** Projection definition for what data to store in Azure Blob. */ -@Immutable +@Fluent public final class SearchIndexerKnowledgeStoreObjectProjectionSelector extends SearchIndexerKnowledgeStoreBlobProjectionSelector { /** @@ -24,4 +26,35 @@ public SearchIndexerKnowledgeStoreObjectProjectionSelector( @JsonProperty(value = "storageContainer", required = true) String storageContainer) { super(storageContainer); } + + @Override + public SearchIndexerKnowledgeStoreObjectProjectionSelector setReferenceKeyName(String referenceKeyName) { + super.setReferenceKeyName(referenceKeyName); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreObjectProjectionSelector setGeneratedKeyName(String generatedKeyName) { + super.setGeneratedKeyName(generatedKeyName); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreObjectProjectionSelector setSource(String source) { + super.setSource(source); + + return this; + } + + @Override + public SearchIndexerKnowledgeStoreObjectProjectionSelector setSourceContext(String sourceContext) { + super.setSourceContext(sourceContext); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreObjectProjectionSelector setInputs(List inputs) { + super.setInputs(inputs); + return this; + } } diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreProjectionSelector.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreProjectionSelector.java index 259adb3fe2c99..7f9fc6f3d80ed 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreProjectionSelector.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreProjectionSelector.java @@ -12,7 +12,7 @@ /** Abstract class to share properties between concrete selectors. */ @Fluent -public class SearchIndexerKnowledgeStoreProjectionSelector { +public abstract class SearchIndexerKnowledgeStoreProjectionSelector { /* * Name of reference key to different projection. */ diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreTableProjectionSelector.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreTableProjectionSelector.java index 12083cefc14ac..d63282bd5b654 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreTableProjectionSelector.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerKnowledgeStoreTableProjectionSelector.java @@ -10,6 +10,8 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + /** Description for what data to store in Azure Tables. */ @Fluent public final class SearchIndexerKnowledgeStoreTableProjectionSelector @@ -39,4 +41,35 @@ public SearchIndexerKnowledgeStoreTableProjectionSelector( public String getTableName() { return this.tableName; } + + @Override + public SearchIndexerKnowledgeStoreTableProjectionSelector setReferenceKeyName(String referenceKeyName) { + super.setReferenceKeyName(referenceKeyName); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreTableProjectionSelector setGeneratedKeyName(String generatedKeyName) { + super.setGeneratedKeyName(generatedKeyName); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreTableProjectionSelector setSource(String source) { + super.setSource(source); + + return this; + } + + @Override + public SearchIndexerKnowledgeStoreTableProjectionSelector setSourceContext(String sourceContext) { + super.setSourceContext(sourceContext); + return this; + } + + @Override + public SearchIndexerKnowledgeStoreTableProjectionSelector setInputs(List inputs) { + super.setInputs(inputs); + return this; + } } diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerSkill.java index 930e4db000e8d..bfff6f6fad665 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SearchIndexerSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSubTypes; @@ -19,7 +18,7 @@ @JsonTypeInfo( use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, - property = "@odata\\.type", + property = "@odata.type", defaultImpl = SearchIndexerSkill.class) @JsonTypeName("SearchIndexerSkill") @JsonSubTypes({ @@ -40,7 +39,6 @@ @JsonSubTypes.Type(name = "#Microsoft.Skills.Util.DocumentExtractionSkill", value = DocumentExtractionSkill.class), @JsonSubTypes.Type(name = "#Microsoft.Skills.Custom.WebApiSkill", value = WebApiSkill.class) }) -@JsonFlatten @Fluent public abstract class SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SentimentSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SentimentSkill.java index 899115242e8da..17b8ac6cc04ec 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SentimentSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SentimentSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -15,9 +14,8 @@ import java.util.List; /** Text analytics positive-negative sentiment analysis, scored as a floating point value in a range of zero to 1. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Text.SentimentSkill") -@JsonFlatten @Fluent public final class SentimentSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ShaperSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ShaperSkill.java index 2c17069090a1f..b546f73dc6db2 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ShaperSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/ShaperSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Immutable; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -18,9 +17,8 @@ * A skill for reshaping the outputs. It creates a complex type to support composite fields (also known as multipart * fields). */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Util.ShaperSkill") -@JsonFlatten @Immutable public final class ShaperSkill extends SearchIndexerSkill { /** diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SimilarityAlgorithm.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SimilarityAlgorithm.java index dca7eaf3b0ad3..93ba6d074406b 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SimilarityAlgorithm.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SimilarityAlgorithm.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Immutable; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonSubTypes; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -20,13 +19,12 @@ @JsonTypeInfo( use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, - property = "@odata\\.type", + property = "@odata.type", defaultImpl = SimilarityAlgorithm.class) @JsonSubTypes({ @JsonSubTypes.Type(name = "#Microsoft.Azure.Search.ClassicSimilarity", value = ClassicSimilarityAlgorithm.class), @JsonSubTypes.Type(name = "#Microsoft.Azure.Search.BM25Similarity", value = BM25SimilarityAlgorithm.class) }) -@JsonFlatten @Immutable @JsonTypeName("Similarity") public abstract class SimilarityAlgorithm { } diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SoftDeleteColumnDeletionDetectionPolicy.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SoftDeleteColumnDeletionDetectionPolicy.java index eb1494f624005..b52637670deeb 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SoftDeleteColumnDeletionDetectionPolicy.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SoftDeleteColumnDeletionDetectionPolicy.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -16,9 +15,8 @@ * Defines a data deletion detection policy that implements a soft-deletion strategy. It determines whether an item * should be deleted based on the value of a designated 'soft delete' column. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.SoftDeleteColumnDeletionDetectionPolicy") -@JsonFlatten @Fluent public final class SoftDeleteColumnDeletionDetectionPolicy extends DataDeletionDetectionPolicy { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SplitSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SplitSkill.java index c51c9ec88b4ab..9c8a58989d4de 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SplitSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SplitSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -15,9 +14,8 @@ import java.util.List; /** A skill to split a string into chunks of text. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Text.SplitSkill") -@JsonFlatten @Fluent public final class SplitSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SqlIntegratedChangeTrackingPolicy.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SqlIntegratedChangeTrackingPolicy.java index aa26f3f85828b..8fa4e869dce5d 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SqlIntegratedChangeTrackingPolicy.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/SqlIntegratedChangeTrackingPolicy.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Immutable; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -15,8 +14,7 @@ * Defines a data change detection policy that captures changes using the Integrated Change Tracking feature of Azure * SQL Database. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.SqlIntegratedChangeTrackingPolicy") -@JsonFlatten @Immutable public final class SqlIntegratedChangeTrackingPolicy extends DataChangeDetectionPolicy { } diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/StopAnalyzer.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/StopAnalyzer.java index 0aa80d8b08490..8316a913792ed 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/StopAnalyzer.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/StopAnalyzer.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSetter; @@ -19,9 +18,8 @@ * Divides text at non-letters; Applies the lowercase and stopword token filters. This analyzer is implemented using * Apache Lucene. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Azure.Search.StopAnalyzer") -@JsonFlatten @Fluent public final class StopAnalyzer extends LexicalAnalyzer { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/TextTranslationSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/TextTranslationSkill.java index 0f166b7175de5..9014a57729276 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/TextTranslationSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/TextTranslationSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -15,9 +14,8 @@ import java.util.List; /** A skill to translate text from one language to another. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Text.TranslationSkill") -@JsonFlatten @Fluent public final class TextTranslationSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/WebApiSkill.java b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/WebApiSkill.java index 5ae7504fdf49f..873b352a11b1a 100644 --- a/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/WebApiSkill.java +++ b/sdk/search/azure-search-documents/src/main/java/com/azure/search/documents/indexes/models/WebApiSkill.java @@ -7,7 +7,6 @@ package com.azure.search.documents.indexes.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -17,9 +16,8 @@ import java.util.Map; /** A skill that can call a Web API endpoint, allowing you to extend a skillset by having it call your custom code. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata\\.type") +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@odata.type") @JsonTypeName("#Microsoft.Skills.Custom.WebApiSkill") -@JsonFlatten @Fluent public final class WebApiSkill extends SearchIndexerSkill { /* diff --git a/sdk/search/azure-search-documents/src/samples/README.md b/sdk/search/azure-search-documents/src/samples/README.md index d34b12c7ae3e9..4cb7e9cd16096 100644 --- a/sdk/search/azure-search-documents/src/samples/README.md +++ b/sdk/search/azure-search-documents/src/samples/README.md @@ -29,7 +29,7 @@ Maven dependency for Azure Cognitive Search Client library. Add it to your proje com.azure azure-search-documents - 11.3.2 + 11.4.0 ``` diff --git a/sdk/search/azure-search-documents/swagger/README.md b/sdk/search/azure-search-documents/swagger/README.md index e0bdf4410462f..702038098a593 100644 --- a/sdk/search/azure-search-documents/swagger/README.md +++ b/sdk/search/azure-search-documents/swagger/README.md @@ -118,6 +118,7 @@ license-header: |- Licensed under the MIT License. Code generated by Microsoft (R) AutoRest Code Generator. Changes may cause incorrect behavior and will be lost if the code is regenerated. +require-x-ms-flattened-to-flatten: true ``` ### Set odata.metadata Accept header in operations diff --git a/sdk/search/azure-search-documents/swagger/src/main/java/SearchServiceCustomizations.java b/sdk/search/azure-search-documents/swagger/src/main/java/SearchServiceCustomizations.java index dfc791f03ad4f..0dc0c449f5e29 100644 --- a/sdk/search/azure-search-documents/swagger/src/main/java/SearchServiceCustomizations.java +++ b/sdk/search/azure-search-documents/swagger/src/main/java/SearchServiceCustomizations.java @@ -40,7 +40,8 @@ public void customize(LibraryCustomization libraryCustomization, Logger logger) // Change class modifiers to 'public abstract'. bulkChangeClassModifiers(publicCustomization, PUBLIC_ABSTRACT, "ScoringFunction", "DataChangeDetectionPolicy", "DataDeletionDetectionPolicy", "CharFilter", "CognitiveServicesAccount", "SearchIndexerSkill", - "LexicalAnalyzer"); + "LexicalAnalyzer", "SearchIndexerKnowledgeStoreProjectionSelector", + "SearchIndexerKnowledgeStoreBlobProjectionSelector"); // Change class modifiers to 'public final'. bulkChangeClassModifiers(publicCustomization, PUBLIC_FINAL, "BM25SimilarityAlgorithm", @@ -75,6 +76,14 @@ public void customize(LibraryCustomization libraryCustomization, Logger logger) customizeLuceneStandardAnalyzer(publicCustomization.getClass("LuceneStandardAnalyzer")); customizeStopAnalyzer(publicCustomization.getClass("StopAnalyzer")); customizeSearchIndexerSkillset(publicCustomization.getClass("SearchIndexerSkillset")); + customizeSearchIndexerKnowledgeStoreBlobProjectionSelector( + publicCustomization.getClass("SearchIndexerKnowledgeStoreBlobProjectionSelector")); + customizeSearchIndexerKnowledgeStoreFileProjectionSelector( + publicCustomization.getClass("SearchIndexerKnowledgeStoreFileProjectionSelector")); + customizeSearchIndexerKnowledgeStoreObjectProjectionSelector( + publicCustomization.getClass("SearchIndexerKnowledgeStoreObjectProjectionSelector")); + customizeSearchIndexerKnowledgeStoreTableProjectionSelector( + publicCustomization.getClass("SearchIndexerKnowledgeStoreTableProjectionSelector")); } private void customizeSearchFieldDataType(ClassCustomization classCustomization) { @@ -347,6 +356,60 @@ private void customizeSearchIndexerSkillset(ClassCustomization classCustomizatio addVarArgsOverload(classCustomization, "skills", "SearchIndexerSkill"); } + private void customizeSearchIndexerKnowledgeStoreBlobProjectionSelector(ClassCustomization classCustomization) { + addKnowledgeStoreProjectionFluentSetterOverrides(classCustomization); + } + + private void customizeSearchIndexerKnowledgeStoreFileProjectionSelector(ClassCustomization classCustomization) { + classCustomization.removeAnnotation("@Immutable"); + classCustomization.addAnnotation("@Fluent"); + addKnowledgeStoreProjectionFluentSetterOverrides(classCustomization); + } + + private void customizeSearchIndexerKnowledgeStoreObjectProjectionSelector(ClassCustomization classCustomization) { + classCustomization.removeAnnotation("@Immutable"); + classCustomization.addAnnotation("@Fluent"); + addKnowledgeStoreProjectionFluentSetterOverrides(classCustomization); + } + + private void customizeSearchIndexerKnowledgeStoreTableProjectionSelector(ClassCustomization classCustomization) { + addKnowledgeStoreProjectionFluentSetterOverrides(classCustomization); + } + + private void addKnowledgeStoreProjectionFluentSetterOverrides(ClassCustomization classCustomization) { + String className = classCustomization.getClassName(); + + classCustomization.addMethod(joinWithNewline( + String.format("public %s setReferenceKeyName(String referenceKeyName) {", className), + " super.setReferenceKeyName(referenceKeyName);", + " return this;", + "}")).addAnnotation("@Override"); + + classCustomization.addMethod(joinWithNewline( + String.format("public %s setGeneratedKeyName(String generatedKeyName) {", className), + " super.setGeneratedKeyName(generatedKeyName);", + " return this;", + "}")).addAnnotation("@Override"); + + classCustomization.addMethod(joinWithNewline( + String.format("public %s setSource(String source) {", className), + " super.setSource(source);\n", + " return this;\n", + "}")).addAnnotation("@Override"); + + classCustomization.addMethod(joinWithNewline( + String.format("public %s setSourceContext(String sourceContext) {", className), + " super.setSourceContext(sourceContext);", + " return this;", + "}")).addAnnotation("@Override"); + + classCustomization.addMethod(joinWithNewline( + String.format("public %s setInputs(List inputs) {", className), + " super.setInputs(inputs);", + " return this;", + "}")).addAnnotation("@Override"); + } + private static void bulkChangeClassModifiers(PackageCustomization packageCustomization, int modifier, String... classNames) { if (classNames == null) { diff --git a/sdk/search/azure-search-perf/pom.xml b/sdk/search/azure-search-perf/pom.xml index 789f7f98fdb1b..4121df10ee73b 100644 --- a/sdk/search/azure-search-perf/pom.xml +++ b/sdk/search/azure-search-perf/pom.xml @@ -32,7 +32,7 @@ com.azure azure-search-documents - 11.4.0-beta.3 + 11.5.0-beta.1 diff --git a/sdk/search/pom.xml b/sdk/search/pom.xml index 75cc749d57f7a..a31fa4944a085 100644 --- a/sdk/search/pom.xml +++ b/sdk/search/pom.xml @@ -19,7 +19,7 @@ com.azure azure-search-documents - 11.4.0-beta.3 + 11.5.0-beta.1