Class LimitTokenFilter
java.lang.Object
com.azure.search.documents.indexes.models.TokenFilter
com.azure.search.documents.indexes.models.LimitTokenFilter
Limits the number of tokens while indexing. This token filter is implemented
using Apache Lucene.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the consumeAllTokens property: A value indicating whether all tokens from the input must be consumed even if maxTokenCount is reached.Get the maxTokenCount property: The maximum number of tokens to produce.setAllTokensConsumed
(Boolean allTokensConsumed) Set the consumeAllTokens property: A value indicating whether all tokens from the input must be consumed even if maxTokenCount is reached.setMaxTokenCount
(Integer maxTokenCount) Set the maxTokenCount property: The maximum number of tokens to produce.Methods inherited from class com.azure.search.documents.indexes.models.TokenFilter
getName
-
Constructor Details
-
LimitTokenFilter
Constructor ofTokenFilter
.- Parameters:
name
- The name of the token filter. It must only contain letters, digits, spaces, dashes or underscores, can only start and end with alphanumeric characters, and is limited to 128 characters.
-
-
Method Details
-
getMaxTokenCount
Get the maxTokenCount property: The maximum number of tokens to produce. Default is 1.- Returns:
- the maxTokenCount value.
-
setMaxTokenCount
Set the maxTokenCount property: The maximum number of tokens to produce. Default is 1.- Parameters:
maxTokenCount
- the maxTokenCount value to set.- Returns:
- the LimitTokenFilter object itself.
-
areAllTokensConsumed
Get the consumeAllTokens property: A value indicating whether all tokens from the input must be consumed even if maxTokenCount is reached. Default is false.- Returns:
- the consumeAllTokens value.
-
setAllTokensConsumed
Set the consumeAllTokens property: A value indicating whether all tokens from the input must be consumed even if maxTokenCount is reached. Default is false.- Parameters:
allTokensConsumed
- the consumeAllTokens value to set.- Returns:
- the LimitTokenFilter object itself.
-