Class TokenFilterDefinition
- java.lang.Object
-
- org.opensearch.client.opensearch._types.analysis.TokenFilterDefinition
-
- All Implemented Interfaces:
JsonpSerializable,TaggedUnion<TokenFilterDefinition.Kind,TokenFilterDefinitionVariant>
@JsonpDeserializable public class TokenFilterDefinition extends java.lang.Object implements TaggedUnion<TokenFilterDefinition.Kind,TokenFilterDefinitionVariant>, JsonpSerializable
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classTokenFilterDefinition.Builderstatic classTokenFilterDefinition.KindTokenFilterDefinitionvariant kinds.
-
Field Summary
Fields Modifier and Type Field Description static JsonpDeserializer<TokenFilterDefinition>_DESERIALIZER
-
Constructor Summary
Constructors Constructor Description TokenFilterDefinition(TokenFilterDefinitionVariant value)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description TokenFilterDefinitionVariant_get()TokenFilterDefinition.Kind_kind()Get the of the kind of variant held by this object.AsciiFoldingTokenFilterasciifolding()Get theasciifoldingvariant value.CommonGramsTokenFiltercommonGrams()Get thecommon_gramsvariant value.ConditionTokenFiltercondition()Get theconditionvariant value.DelimitedPayloadTokenFilterdelimitedPayload()Get thedelimited_payloadvariant value.DictionaryDecompounderTokenFilterdictionaryDecompounder()Get thedictionary_decompoundervariant value.EdgeNGramTokenFilteredgeNgram()Get theedge_ngramvariant value.ElisionTokenFilterelision()Get theelisionvariant value.FingerprintTokenFilterfingerprint()Get thefingerprintvariant value.HunspellTokenFilterhunspell()Get thehunspellvariant value.HyphenationDecompounderTokenFilterhyphenationDecompounder()Get thehyphenation_decompoundervariant value.IcuCollationTokenFiltericuCollation()Get theicu_collationvariant value.IcuFoldingTokenFiltericuFolding()Get theicu_foldingvariant value.IcuNormalizationTokenFiltericuNormalizer()Get theicu_normalizervariant value.IcuTokenizericuTokenizer()Get theicu_tokenizervariant value.IcuTransformTokenFiltericuTransform()Get theicu_transformvariant value.booleanisAsciifolding()Is this variant instance of kindasciifolding?booleanisCommonGrams()Is this variant instance of kindcommon_grams?booleanisCondition()Is this variant instance of kindcondition?booleanisDelimitedPayload()Is this variant instance of kinddelimited_payload?booleanisDictionaryDecompounder()Is this variant instance of kinddictionary_decompounder?booleanisEdgeNgram()Is this variant instance of kindedge_ngram?booleanisElision()Is this variant instance of kindelision?booleanisFingerprint()Is this variant instance of kindfingerprint?booleanisHunspell()Is this variant instance of kindhunspell?booleanisHyphenationDecompounder()Is this variant instance of kindhyphenation_decompounder?booleanisIcuCollation()Is this variant instance of kindicu_collation?booleanisIcuFolding()Is this variant instance of kindicu_folding?booleanisIcuNormalizer()Is this variant instance of kindicu_normalizer?booleanisIcuTokenizer()Is this variant instance of kindicu_tokenizer?booleanisIcuTransform()Is this variant instance of kindicu_transform?booleanisKeep()Is this variant instance of kindkeep?booleanisKeepTypes()Is this variant instance of kindkeep_types?booleanisKeywordMarker()Is this variant instance of kindkeyword_marker?booleanisKstem()Is this variant instance of kindkstem?booleanisKuromojiPartOfSpeech()Is this variant instance of kindkuromoji_part_of_speech?booleanisKuromojiReadingform()Is this variant instance of kindkuromoji_readingform?booleanisKuromojiStemmer()Is this variant instance of kindkuromoji_stemmer?booleanisLength()Is this variant instance of kindlength?booleanisLimit()Is this variant instance of kindlimit?booleanisLowercase()Is this variant instance of kindlowercase?booleanisMultiplexer()Is this variant instance of kindmultiplexer?booleanisNgram()Is this variant instance of kindngram?booleanisNoriPartOfSpeech()Is this variant instance of kindnori_part_of_speech?booleanisPatternCapture()Is this variant instance of kindpattern_capture?booleanisPatternReplace()Is this variant instance of kindpattern_replace?booleanisPhonetic()Is this variant instance of kindphonetic?booleanisPorterStem()Is this variant instance of kindporter_stem?booleanisPredicateTokenFilter()Is this variant instance of kindpredicate_token_filter?booleanisRemoveDuplicates()Is this variant instance of kindremove_duplicates?booleanisReverse()Is this variant instance of kindreverse?booleanisShingle()Is this variant instance of kindshingle?booleanisSnowball()Is this variant instance of kindsnowball?booleanisStemmer()Is this variant instance of kindstemmer?booleanisStemmerOverride()Is this variant instance of kindstemmer_override?booleanisStop()Is this variant instance of kindstop?booleanisSynonym()Is this variant instance of kindsynonym?booleanisSynonymGraph()Is this variant instance of kindsynonym_graph?booleanisTrim()Is this variant instance of kindtrim?booleanisTruncate()Is this variant instance of kindtruncate?booleanisUnique()Is this variant instance of kindunique?booleanisUppercase()Is this variant instance of kinduppercase?booleanisWordDelimiter()Is this variant instance of kindword_delimiter?booleanisWordDelimiterGraph()Is this variant instance of kindword_delimiter_graph?KeepWordsTokenFilterkeep()Get thekeepvariant value.KeepTypesTokenFilterkeepTypes()Get thekeep_typesvariant value.KeywordMarkerTokenFilterkeywordMarker()Get thekeyword_markervariant value.KStemTokenFilterkstem()Get thekstemvariant value.KuromojiPartOfSpeechTokenFilterkuromojiPartOfSpeech()Get thekuromoji_part_of_speechvariant value.KuromojiReadingFormTokenFilterkuromojiReadingform()Get thekuromoji_readingformvariant value.KuromojiStemmerTokenFilterkuromojiStemmer()Get thekuromoji_stemmervariant value.LengthTokenFilterlength()Get thelengthvariant value.LimitTokenCountTokenFilterlimit()Get thelimitvariant value.LowercaseTokenFilterlowercase()Get thelowercasevariant value.MultiplexerTokenFiltermultiplexer()Get themultiplexervariant value.NGramTokenFilterngram()Get thengramvariant value.NoriPartOfSpeechTokenFilternoriPartOfSpeech()Get thenori_part_of_speechvariant value.static TokenFilterDefinitionof(java.util.function.Function<TokenFilterDefinition.Builder,ObjectBuilder<TokenFilterDefinition>> fn)PatternCaptureTokenFilterpatternCapture()Get thepattern_capturevariant value.PatternReplaceTokenFilterpatternReplace()Get thepattern_replacevariant value.PhoneticTokenFilterphonetic()Get thephoneticvariant value.PorterStemTokenFilterporterStem()Get theporter_stemvariant value.PredicateTokenFilterpredicateTokenFilter()Get thepredicate_token_filtervariant value.RemoveDuplicatesTokenFilterremoveDuplicates()Get theremove_duplicatesvariant value.ReverseTokenFilterreverse()Get thereversevariant value.voidserialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)protected static voidsetupTokenFilterDefinitionDeserializer(ObjectDeserializer<TokenFilterDefinition.Builder> op)ShingleTokenFiltershingle()Get theshinglevariant value.SnowballTokenFiltersnowball()Get thesnowballvariant value.StemmerTokenFilterstemmer()Get thestemmervariant value.StemmerOverrideTokenFilterstemmerOverride()Get thestemmer_overridevariant value.StopTokenFilterstop()Get thestopvariant value.SynonymTokenFiltersynonym()Get thesynonymvariant value.SynonymGraphTokenFiltersynonymGraph()Get thesynonym_graphvariant value.TrimTokenFiltertrim()Get thetrimvariant value.TruncateTokenFiltertruncate()Get thetruncatevariant value.UniqueTokenFilterunique()Get theuniquevariant value.UppercaseTokenFilteruppercase()Get theuppercasevariant value.WordDelimiterTokenFilterwordDelimiter()Get theword_delimitervariant value.WordDelimiterGraphTokenFilterwordDelimiterGraph()Get theword_delimiter_graphvariant value.
-
-
-
Field Detail
-
_DESERIALIZER
public static final JsonpDeserializer<TokenFilterDefinition> _DESERIALIZER
-
-
Constructor Detail
-
TokenFilterDefinition
public TokenFilterDefinition(TokenFilterDefinitionVariant value)
-
-
Method Detail
-
_kind
public final TokenFilterDefinition.Kind _kind()
Description copied from interface:TaggedUnionGet the of the kind of variant held by this object.- Specified by:
_kindin interfaceTaggedUnion<TokenFilterDefinition.Kind,TokenFilterDefinitionVariant>- Returns:
- the variant kind
-
_get
public final TokenFilterDefinitionVariant _get()
- Specified by:
_getin interfaceTaggedUnion<TokenFilterDefinition.Kind,TokenFilterDefinitionVariant>
-
of
public static TokenFilterDefinition of(java.util.function.Function<TokenFilterDefinition.Builder,ObjectBuilder<TokenFilterDefinition>> fn)
-
isAsciifolding
public boolean isAsciifolding()
Is this variant instance of kindasciifolding?
-
asciifolding
public AsciiFoldingTokenFilter asciifolding()
Get theasciifoldingvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theasciifoldingkind.
-
isCommonGrams
public boolean isCommonGrams()
Is this variant instance of kindcommon_grams?
-
commonGrams
public CommonGramsTokenFilter commonGrams()
Get thecommon_gramsvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thecommon_gramskind.
-
isCondition
public boolean isCondition()
Is this variant instance of kindcondition?
-
condition
public ConditionTokenFilter condition()
Get theconditionvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theconditionkind.
-
isDelimitedPayload
public boolean isDelimitedPayload()
Is this variant instance of kinddelimited_payload?
-
delimitedPayload
public DelimitedPayloadTokenFilter delimitedPayload()
Get thedelimited_payloadvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thedelimited_payloadkind.
-
isDictionaryDecompounder
public boolean isDictionaryDecompounder()
Is this variant instance of kinddictionary_decompounder?
-
dictionaryDecompounder
public DictionaryDecompounderTokenFilter dictionaryDecompounder()
Get thedictionary_decompoundervariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thedictionary_decompounderkind.
-
isEdgeNgram
public boolean isEdgeNgram()
Is this variant instance of kindedge_ngram?
-
edgeNgram
public EdgeNGramTokenFilter edgeNgram()
Get theedge_ngramvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theedge_ngramkind.
-
isElision
public boolean isElision()
Is this variant instance of kindelision?
-
elision
public ElisionTokenFilter elision()
Get theelisionvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theelisionkind.
-
isFingerprint
public boolean isFingerprint()
Is this variant instance of kindfingerprint?
-
fingerprint
public FingerprintTokenFilter fingerprint()
Get thefingerprintvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thefingerprintkind.
-
isHunspell
public boolean isHunspell()
Is this variant instance of kindhunspell?
-
hunspell
public HunspellTokenFilter hunspell()
Get thehunspellvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thehunspellkind.
-
isHyphenationDecompounder
public boolean isHyphenationDecompounder()
Is this variant instance of kindhyphenation_decompounder?
-
hyphenationDecompounder
public HyphenationDecompounderTokenFilter hyphenationDecompounder()
Get thehyphenation_decompoundervariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thehyphenation_decompounderkind.
-
isIcuCollation
public boolean isIcuCollation()
Is this variant instance of kindicu_collation?
-
icuCollation
public IcuCollationTokenFilter icuCollation()
Get theicu_collationvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theicu_collationkind.
-
isIcuFolding
public boolean isIcuFolding()
Is this variant instance of kindicu_folding?
-
icuFolding
public IcuFoldingTokenFilter icuFolding()
Get theicu_foldingvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theicu_foldingkind.
-
isIcuNormalizer
public boolean isIcuNormalizer()
Is this variant instance of kindicu_normalizer?
-
icuNormalizer
public IcuNormalizationTokenFilter icuNormalizer()
Get theicu_normalizervariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theicu_normalizerkind.
-
isIcuTokenizer
public boolean isIcuTokenizer()
Is this variant instance of kindicu_tokenizer?
-
icuTokenizer
public IcuTokenizer icuTokenizer()
Get theicu_tokenizervariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theicu_tokenizerkind.
-
isIcuTransform
public boolean isIcuTransform()
Is this variant instance of kindicu_transform?
-
icuTransform
public IcuTransformTokenFilter icuTransform()
Get theicu_transformvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theicu_transformkind.
-
isKstem
public boolean isKstem()
Is this variant instance of kindkstem?
-
kstem
public KStemTokenFilter kstem()
Get thekstemvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thekstemkind.
-
isKeepTypes
public boolean isKeepTypes()
Is this variant instance of kindkeep_types?
-
keepTypes
public KeepTypesTokenFilter keepTypes()
Get thekeep_typesvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thekeep_typeskind.
-
isKeep
public boolean isKeep()
Is this variant instance of kindkeep?
-
keep
public KeepWordsTokenFilter keep()
Get thekeepvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thekeepkind.
-
isKeywordMarker
public boolean isKeywordMarker()
Is this variant instance of kindkeyword_marker?
-
keywordMarker
public KeywordMarkerTokenFilter keywordMarker()
Get thekeyword_markervariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thekeyword_markerkind.
-
isKuromojiPartOfSpeech
public boolean isKuromojiPartOfSpeech()
Is this variant instance of kindkuromoji_part_of_speech?
-
kuromojiPartOfSpeech
public KuromojiPartOfSpeechTokenFilter kuromojiPartOfSpeech()
Get thekuromoji_part_of_speechvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thekuromoji_part_of_speechkind.
-
isKuromojiReadingform
public boolean isKuromojiReadingform()
Is this variant instance of kindkuromoji_readingform?
-
kuromojiReadingform
public KuromojiReadingFormTokenFilter kuromojiReadingform()
Get thekuromoji_readingformvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thekuromoji_readingformkind.
-
isKuromojiStemmer
public boolean isKuromojiStemmer()
Is this variant instance of kindkuromoji_stemmer?
-
kuromojiStemmer
public KuromojiStemmerTokenFilter kuromojiStemmer()
Get thekuromoji_stemmervariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thekuromoji_stemmerkind.
-
isLength
public boolean isLength()
Is this variant instance of kindlength?
-
length
public LengthTokenFilter length()
Get thelengthvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thelengthkind.
-
isLimit
public boolean isLimit()
Is this variant instance of kindlimit?
-
limit
public LimitTokenCountTokenFilter limit()
Get thelimitvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thelimitkind.
-
isLowercase
public boolean isLowercase()
Is this variant instance of kindlowercase?
-
lowercase
public LowercaseTokenFilter lowercase()
Get thelowercasevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thelowercasekind.
-
isMultiplexer
public boolean isMultiplexer()
Is this variant instance of kindmultiplexer?
-
multiplexer
public MultiplexerTokenFilter multiplexer()
Get themultiplexervariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of themultiplexerkind.
-
isNgram
public boolean isNgram()
Is this variant instance of kindngram?
-
ngram
public NGramTokenFilter ngram()
Get thengramvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thengramkind.
-
isNoriPartOfSpeech
public boolean isNoriPartOfSpeech()
Is this variant instance of kindnori_part_of_speech?
-
noriPartOfSpeech
public NoriPartOfSpeechTokenFilter noriPartOfSpeech()
Get thenori_part_of_speechvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thenori_part_of_speechkind.
-
isPatternCapture
public boolean isPatternCapture()
Is this variant instance of kindpattern_capture?
-
patternCapture
public PatternCaptureTokenFilter patternCapture()
Get thepattern_capturevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thepattern_capturekind.
-
isPatternReplace
public boolean isPatternReplace()
Is this variant instance of kindpattern_replace?
-
patternReplace
public PatternReplaceTokenFilter patternReplace()
Get thepattern_replacevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thepattern_replacekind.
-
isPhonetic
public boolean isPhonetic()
Is this variant instance of kindphonetic?
-
phonetic
public PhoneticTokenFilter phonetic()
Get thephoneticvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thephonetickind.
-
isPorterStem
public boolean isPorterStem()
Is this variant instance of kindporter_stem?
-
porterStem
public PorterStemTokenFilter porterStem()
Get theporter_stemvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theporter_stemkind.
-
isPredicateTokenFilter
public boolean isPredicateTokenFilter()
Is this variant instance of kindpredicate_token_filter?
-
predicateTokenFilter
public PredicateTokenFilter predicateTokenFilter()
Get thepredicate_token_filtervariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thepredicate_token_filterkind.
-
isRemoveDuplicates
public boolean isRemoveDuplicates()
Is this variant instance of kindremove_duplicates?
-
removeDuplicates
public RemoveDuplicatesTokenFilter removeDuplicates()
Get theremove_duplicatesvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theremove_duplicateskind.
-
isReverse
public boolean isReverse()
Is this variant instance of kindreverse?
-
reverse
public ReverseTokenFilter reverse()
Get thereversevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thereversekind.
-
isShingle
public boolean isShingle()
Is this variant instance of kindshingle?
-
shingle
public ShingleTokenFilter shingle()
Get theshinglevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theshinglekind.
-
isSnowball
public boolean isSnowball()
Is this variant instance of kindsnowball?
-
snowball
public SnowballTokenFilter snowball()
Get thesnowballvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thesnowballkind.
-
isStemmerOverride
public boolean isStemmerOverride()
Is this variant instance of kindstemmer_override?
-
stemmerOverride
public StemmerOverrideTokenFilter stemmerOverride()
Get thestemmer_overridevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thestemmer_overridekind.
-
isStemmer
public boolean isStemmer()
Is this variant instance of kindstemmer?
-
stemmer
public StemmerTokenFilter stemmer()
Get thestemmervariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thestemmerkind.
-
isStop
public boolean isStop()
Is this variant instance of kindstop?
-
stop
public StopTokenFilter stop()
Get thestopvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thestopkind.
-
isSynonymGraph
public boolean isSynonymGraph()
Is this variant instance of kindsynonym_graph?
-
synonymGraph
public SynonymGraphTokenFilter synonymGraph()
Get thesynonym_graphvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thesynonym_graphkind.
-
isSynonym
public boolean isSynonym()
Is this variant instance of kindsynonym?
-
synonym
public SynonymTokenFilter synonym()
Get thesynonymvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thesynonymkind.
-
isTrim
public boolean isTrim()
Is this variant instance of kindtrim?
-
trim
public TrimTokenFilter trim()
Get thetrimvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thetrimkind.
-
isTruncate
public boolean isTruncate()
Is this variant instance of kindtruncate?
-
truncate
public TruncateTokenFilter truncate()
Get thetruncatevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thetruncatekind.
-
isUnique
public boolean isUnique()
Is this variant instance of kindunique?
-
unique
public UniqueTokenFilter unique()
Get theuniquevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theuniquekind.
-
isUppercase
public boolean isUppercase()
Is this variant instance of kinduppercase?
-
uppercase
public UppercaseTokenFilter uppercase()
Get theuppercasevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theuppercasekind.
-
isWordDelimiterGraph
public boolean isWordDelimiterGraph()
Is this variant instance of kindword_delimiter_graph?
-
wordDelimiterGraph
public WordDelimiterGraphTokenFilter wordDelimiterGraph()
Get theword_delimiter_graphvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theword_delimiter_graphkind.
-
isWordDelimiter
public boolean isWordDelimiter()
Is this variant instance of kindword_delimiter?
-
wordDelimiter
public WordDelimiterTokenFilter wordDelimiter()
Get theword_delimitervariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theword_delimiterkind.
-
serialize
public void serialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)- Specified by:
serializein interfaceJsonpSerializable
-
setupTokenFilterDefinitionDeserializer
protected static void setupTokenFilterDefinitionDeserializer(ObjectDeserializer<TokenFilterDefinition.Builder> op)
-
-