Class ConditionTokenFilterDescriptor
The conditional token filter takes a predicate script and a list of subfilters, and
only applies the subfilters to the current token if it matches the predicate.
Inheritance
ConditionTokenFilterDescriptor
Assembly: OpenSearch.Client.dll
Syntax
public class ConditionTokenFilterDescriptor : TokenFilterDescriptorBase<ConditionTokenFilterDescriptor, IConditionTokenFilter>, IDescriptor, IConditionTokenFilter, ITokenFilter
Properties
|
Edit this page
View Source
Type
Declaration
protected override string Type { get; }
Property Value
Overrides
Methods
|
Edit this page
View Source
Filters(IEnumerable<string>)
a chain of token filters to apply to the current token if the predicate
matches. These can be any token filters defined elsewhere in the index mappings.
Declaration
public ConditionTokenFilterDescriptor Filters(IEnumerable<string> filters)
Parameters
Returns
|
Edit this page
View Source
Filters(params string[])
a chain of token filters to apply to the current token if the predicate
matches. These can be any token filters defined elsewhere in the index mappings.
Declaration
public ConditionTokenFilterDescriptor Filters(params string[] filters)
Parameters
Type |
Name |
Description |
string[] |
filters |
|
Returns
|
Edit this page
View Source
Script(Func<ScriptDescriptor, IScript>)
a predicate script that determines whether or not the filters will be applied
to the current token. Note that only inline scripts are supported
Declaration
public ConditionTokenFilterDescriptor Script(Func<ScriptDescriptor, IScript> scriptSelector)
Parameters
Returns
|
Edit this page
View Source
Script(string)
a predicate script that determines whether or not the filters will be applied
to the current token. Note that only inline scripts are supported
Declaration
public ConditionTokenFilterDescriptor Script(string predicate)
Parameters
Type |
Name |
Description |
string |
predicate |
|
Returns
Implements
Extension Methods