Class CustomNormalizer
java.lang.Object
com.azure.search.documents.indexes.models.LexicalNormalizer
com.azure.search.documents.indexes.models.CustomNormalizer
- All Implemented Interfaces:
com.azure.json.JsonSerializable<LexicalNormalizer>
Allows you to configure normalization for filterable, sortable, and facetable fields, which by default operate with
strict matching. This is a user-defined configuration consisting of at least one or more filters, which modify the
token that is stored.
-
Constructor Summary
ConstructorsConstructorDescriptionCustomNormalizer(String name) Creates an instance of CustomNormalizer class. -
Method Summary
Modifier and TypeMethodDescriptionstatic CustomNormalizerfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of CustomNormalizer from the JsonReader.Get the charFilters property: A list of character filters used to prepare input text before it is processed.Get the odataType property: A URI fragment specifying the type of normalizer.Get the tokenFilters property: A list of token filters used to filter out or modify the input token.setCharFilters(List<CharFilterName> charFilters) Set the charFilters property: A list of character filters used to prepare input text before it is processed.setTokenFilters(List<TokenFilterName> tokenFilters) Set the tokenFilters property: A list of token filters used to filter out or modify the input token.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) Methods inherited from class com.azure.search.documents.indexes.models.LexicalNormalizer
getNameMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
CustomNormalizer
Creates an instance of CustomNormalizer class.- Parameters:
name- the name value to set.
-
-
Method Details
-
getOdataType
Get the odataType property: A URI fragment specifying the type of normalizer.- Overrides:
getOdataTypein classLexicalNormalizer- Returns:
- the odataType value.
-
getTokenFilters
Get the tokenFilters property: A list of token filters used to filter out or modify the input token. For example, you can specify a lowercase filter that converts all characters to lowercase. The filters are run in the order in which they are listed.- Returns:
- the tokenFilters value.
-
setTokenFilters
Set the tokenFilters property: A list of token filters used to filter out or modify the input token. For example, you can specify a lowercase filter that converts all characters to lowercase. The filters are run in the order in which they are listed.- Parameters:
tokenFilters- the tokenFilters value to set.- Returns:
- the CustomNormalizer object itself.
-
getCharFilters
Get the charFilters property: A list of character filters used to prepare input text before it is processed. For instance, they can replace certain characters or symbols. The filters are run in the order in which they are listed.- Returns:
- the charFilters value.
-
setCharFilters
Set the charFilters property: A list of character filters used to prepare input text before it is processed. For instance, they can replace certain characters or symbols. The filters are run in the order in which they are listed.- Parameters:
charFilters- the charFilters value to set.- Returns:
- the CustomNormalizer object itself.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<LexicalNormalizer>- Overrides:
toJsonin classLexicalNormalizer- Throws:
IOException
-
fromJson
Reads an instance of CustomNormalizer from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of CustomNormalizer if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IllegalStateException- If the deserialized JSON object was missing any required properties.IOException- If an error occurs while reading the CustomNormalizer.
-