Class QueryContainerDescriptor<T>
Inheritance
QueryContainerDescriptor<T>
Assembly: OpenSearch.Client.dll
Syntax
[DataContract]
public class QueryContainerDescriptor<T> : QueryContainer, IQueryContainer, IDescriptor where T : class
Type Parameters
Methods
|
Edit this page
View Source
Bool(Func<BoolQueryDescriptor<T>, IBoolQuery>)
A query that matches documents matching boolean combinations of other queries. The bool query maps to
Lucene BooleanQuery.
It is built using one or more boolean clauses, each clause with a typed occurrence
Declaration
public QueryContainer Bool(Func<BoolQueryDescriptor<T>, IBoolQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Boosting(Func<BoostingQueryDescriptor<T>, IBoostingQuery>)
A query that can be used to effectively demote results that match a given query.
Unlike the "must_not" clause in bool query, this still selects documents that contain
undesirable terms, but reduces their overall score.
Declaration
public QueryContainer Boosting(Func<BoostingQueryDescriptor<T>, IBoostingQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Conditionless(Func<ConditionlessQueryDescriptor<T>, IConditionlessQuery>)
A thin wrapper allowing fined grained control what should happen if a query is conditionless
if you need to fallback to something other than a match_all query
Declaration
public QueryContainer Conditionless(Func<ConditionlessQueryDescriptor<T>, IConditionlessQuery> selector)
Parameters
Returns
|
Edit this page
View Source
ConstantScore(Func<ConstantScoreQueryDescriptor<T>, IConstantScoreQuery>)
A query that wraps a filter or another query and simply returns a constant score equal to the query boost
for every document in the filter. Maps to Lucene ConstantScoreQuery.
Declaration
public QueryContainer ConstantScore(Func<ConstantScoreQueryDescriptor<T>, IConstantScoreQuery> selector)
Parameters
Returns
|
Edit this page
View Source
DateRange(Func<DateRangeQueryDescriptor<T>, IDateRangeQuery>)
Matches documents with fields that have terms within a certain date range.
Declaration
public QueryContainer DateRange(Func<DateRangeQueryDescriptor<T>, IDateRangeQuery> selector)
Parameters
Returns
|
Edit this page
View Source
DisMax(Func<DisMaxQueryDescriptor<T>, IDisMaxQuery>)
A query that generates the union of documents produced by its subqueries, and that scores each document
with the maximum score for that document as produced by any subquery, plus a tie breaking increment for
any additional matching subqueries.
Declaration
public QueryContainer DisMax(Func<DisMaxQueryDescriptor<T>, IDisMaxQuery> selector)
Parameters
Returns
|
Edit this page
View Source
DistanceFeature(Func<DistanceFeatureQueryDescriptor<T>, IDistanceFeatureQuery>)
Boosts the relevance score of documents closer to a provided origin date or point. For example, you can use this query to give
more weight to documents closer to a certain date or location.
You can use the distance_feature query to find the nearest neighbors to a location. You can also use the query in a bool
search’s should filter to add boosted relevance scores to the bool query’s scores.
Declaration
public QueryContainer DistanceFeature(Func<DistanceFeatureQueryDescriptor<T>, IDistanceFeatureQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Exists(Func<ExistsQueryDescriptor<T>, IExistsQuery>)
Declaration
public QueryContainer Exists(Func<ExistsQueryDescriptor<T>, IExistsQuery> selector)
Parameters
Returns
|
Edit this page
View Source
FunctionScore(Func<FunctionScoreQueryDescriptor<T>, IFunctionScoreQuery>)
The function_score query allows you to modify the score of documents that are retrieved by a query.
This can be useful if, for example, a score function is computationally expensive and it is
sufficient to compute the score on a filtered set of documents.
Declaration
public QueryContainer FunctionScore(Func<FunctionScoreQueryDescriptor<T>, IFunctionScoreQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Fuzzy(Func<FuzzyQueryDescriptor<T>, IFuzzyQuery>)
A fuzzy based query that uses similarity based on Levenshtein (edit distance) algorithm.
Warning: this query is not very scalable with its default prefix length of 0. In this case,
every term will be enumerated and cause an edit score calculation or max_expansions is not set.
Declaration
public QueryContainer Fuzzy(Func<FuzzyQueryDescriptor<T>, IFuzzyQuery> selector)
Parameters
Returns
|
Edit this page
View Source
FuzzyDate(Func<FuzzyDateQueryDescriptor<T>, IFuzzyQuery>)
Declaration
public QueryContainer FuzzyDate(Func<FuzzyDateQueryDescriptor<T>, IFuzzyQuery> selector)
Parameters
Returns
|
Edit this page
View Source
FuzzyNumeric(Func<FuzzyNumericQueryDescriptor<T>, IFuzzyQuery>)
Declaration
public QueryContainer FuzzyNumeric(Func<FuzzyNumericQueryDescriptor<T>, IFuzzyQuery> selector)
Parameters
Returns
|
Edit this page
View Source
GeoBoundingBox(Func<GeoBoundingBoxQueryDescriptor<T>, IGeoBoundingBoxQuery>)
Matches documents with a geo_point type field to include only those that exist within a bounding box
Declaration
public QueryContainer GeoBoundingBox(Func<GeoBoundingBoxQueryDescriptor<T>, IGeoBoundingBoxQuery> selector)
Parameters
Returns
|
Edit this page
View Source
GeoDistance(Func<GeoDistanceQueryDescriptor<T>, IGeoDistanceQuery>)
Matches documents with a geo_point type field to include only those
that exist within a specific distance from a given geo_point
Declaration
public QueryContainer GeoDistance(Func<GeoDistanceQueryDescriptor<T>, IGeoDistanceQuery> selector)
Parameters
Returns
|
Edit this page
View Source
GeoPolygon(Func<GeoPolygonQueryDescriptor<T>, IGeoPolygonQuery>)
Matches documents with a geo_point type field that falls within a polygon of points
Declaration
public QueryContainer GeoPolygon(Func<GeoPolygonQueryDescriptor<T>, IGeoPolygonQuery> selector)
Parameters
Returns
|
Edit this page
View Source
GeoShape(Func<GeoShapeQueryDescriptor<T>, IGeoShapeQuery>)
A geo_shape query that finds documents
that have a geometry that matches for the given spatial relation and input shape
Declaration
public QueryContainer GeoShape(Func<GeoShapeQueryDescriptor<T>, IGeoShapeQuery> selector)
Parameters
Returns
|
Edit this page
View Source
HasChild<TChild>(Func<HasChildQueryDescriptor<TChild>, IHasChildQuery>)
The has_child query works the same as the has_child filter, by automatically wrapping the filter with a
constant_score.
Declaration
public QueryContainer HasChild<TChild>(Func<HasChildQueryDescriptor<TChild>, IHasChildQuery> selector) where TChild : class
Parameters
Returns
Type Parameters
Name |
Description |
TChild |
Type of the child
|
|
Edit this page
View Source
HasParent<TParent>(Func<HasParentQueryDescriptor<TParent>, IHasParentQuery>)
The has_parent query works the same as the has_parent filter, by automatically wrapping the filter with a
constant_score.
Declaration
public QueryContainer HasParent<TParent>(Func<HasParentQueryDescriptor<TParent>, IHasParentQuery> selector) where TParent : class
Parameters
Returns
Type Parameters
Name |
Description |
TParent |
Type of the parent
|
|
Edit this page
View Source
HasRelationName(Expression<Func<T, JoinField>>, RelationName)
Helper method to easily filter on join relations
Declaration
public QueryContainer HasRelationName(Expression<Func<T, JoinField>> field, RelationName value)
Parameters
Returns
|
Edit this page
View Source
HasRelationName<TRelation>(Expression<Func<T, JoinField>>)
Helper method to easily filter on join relations
Declaration
public QueryContainer HasRelationName<TRelation>(Expression<Func<T, JoinField>> field)
Parameters
Returns
Type Parameters
Name |
Description |
TRelation |
|
|
Edit this page
View Source
Ids(Func<IdsQueryDescriptor, IIdsQuery>)
Matches documents that only have the provided ids.
Note, this filter does not require the _id field to be indexed since
it works using the _uid field.
Declaration
public QueryContainer Ids(Func<IdsQueryDescriptor, IIdsQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Intervals(Func<IntervalsQueryDescriptor<T>, IIntervalsQuery>)
Allows fine-grained control over the order and proximity of matching terms.
Matching rules are constructed from a small set of definitions,
and the rules are then applied to terms from a particular field.
The definitions produce sequences of minimal intervals that span terms in a body of text.
These intervals can be further combined and filtered by parent sources.
Declaration
public QueryContainer Intervals(Func<IntervalsQueryDescriptor<T>, IIntervalsQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Knn(Func<KnnQueryDescriptor<T>, IKnnQuery>)
Declaration
public QueryContainer Knn(Func<KnnQueryDescriptor<T>, IKnnQuery> selector)
Parameters
Returns
|
Edit this page
View Source
LongRange(Func<LongRangeQueryDescriptor<T>, ILongRangeQuery>)
Declaration
public QueryContainer LongRange(Func<LongRangeQueryDescriptor<T>, ILongRangeQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Match(Func<MatchQueryDescriptor<T>, IMatchQuery>)
The default match query is of type boolean. It means that the text provided is analyzed and the analysis
process constructs a boolean query from the provided text.
Declaration
public QueryContainer Match(Func<MatchQueryDescriptor<T>, IMatchQuery> selector)
Parameters
Returns
|
Edit this page
View Source
MatchAll(Func<MatchAllQueryDescriptor, IMatchAllQuery>)
A query that matches all documents. Maps to Lucene MatchAllDocsQuery.
Declaration
public QueryContainer MatchAll(Func<MatchAllQueryDescriptor, IMatchAllQuery> selector = null)
Parameters
Returns
|
Edit this page
View Source
MatchBoolPrefix(Func<MatchBoolPrefixQueryDescriptor<T>, IMatchBoolPrefixQuery>)
A match_bool_prefix query analyzes its input and constructs a bool query from the terms.
Each term except the last is used in a term query. The last term is used in a prefix query.
Declaration
public QueryContainer MatchBoolPrefix(Func<MatchBoolPrefixQueryDescriptor<T>, IMatchBoolPrefixQuery> selector)
Parameters
Returns
|
Edit this page
View Source
MatchNone(Func<MatchNoneQueryDescriptor, IMatchNoneQuery>)
A query that matches no documents. This is the inverse of the match_all query.
Declaration
public QueryContainer MatchNone(Func<MatchNoneQueryDescriptor, IMatchNoneQuery> selector = null)
Parameters
Returns
|
Edit this page
View Source
MatchPhrase(Func<MatchPhraseQueryDescriptor<T>, IMatchPhraseQuery>)
The match_phrase query analyzes the match and creates a phrase query out of the analyzed text.
Declaration
public QueryContainer MatchPhrase(Func<MatchPhraseQueryDescriptor<T>, IMatchPhraseQuery> selector)
Parameters
Returns
|
Edit this page
View Source
MatchPhrasePrefix(Func<MatchPhrasePrefixQueryDescriptor<T>, IMatchPhrasePrefixQuery>)
The match_phrase_prefix is the same as match_phrase, expect it allows for prefix matches on the last term
in the text
Declaration
public QueryContainer MatchPhrasePrefix(Func<MatchPhrasePrefixQueryDescriptor<T>, IMatchPhrasePrefixQuery> selector)
Parameters
Returns
|
Edit this page
View Source
MoreLikeThis(Func<MoreLikeThisQueryDescriptor<T>, IMoreLikeThisQuery>)
More like this query find documents that are like the provided text by running it against one or more fields.
Declaration
public QueryContainer MoreLikeThis(Func<MoreLikeThisQueryDescriptor<T>, IMoreLikeThisQuery> selector)
Parameters
Returns
|
Edit this page
View Source
MultiMatch(Func<MultiMatchQueryDescriptor<T>, IMultiMatchQuery>)
The multi_match query builds further on top of the match query by allowing multiple fields to be specified.
The idea here is to allow to more easily build a concise match type query over multiple fields instead of using a
relatively more expressive query by using multiple match queries within a bool query.
Declaration
public QueryContainer MultiMatch(Func<MultiMatchQueryDescriptor<T>, IMultiMatchQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Nested(Func<NestedQueryDescriptor<T>, INestedQuery>)
Nested query allows to query nested objects / docs (see nested mapping). The query is executed against the
nested objects / docs as if they were indexed as separate docs (they are, internally) and resulting in the
root parent doc (or parent nested mapping).
Declaration
public QueryContainer Nested(Func<NestedQueryDescriptor<T>, INestedQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Neural(Func<NeuralQueryDescriptor<T>, INeuralQuery>)
Declaration
public QueryContainer Neural(Func<NeuralQueryDescriptor<T>, INeuralQuery> selector)
Parameters
Returns
|
Edit this page
View Source
ParentId(Func<ParentIdQueryDescriptor<T>, IParentIdQuery>)
Used to find child documents which belong to a particular parent.
Declaration
public QueryContainer ParentId(Func<ParentIdQueryDescriptor<T>, IParentIdQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Percolate(Func<PercolateQueryDescriptor<T>, IPercolateQuery>)
Used to match queries stored in an index.
The percolate query itself contains the document that will be used as query
to match with the stored queries.
Declaration
public QueryContainer Percolate(Func<PercolateQueryDescriptor<T>, IPercolateQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Prefix(Field, string, double?, MultiTermQueryRewrite, string)
Matches documents that have fields containing terms with a specified prefix (not analyzed).
The prefix query maps to Lucene PrefixQuery.
Declaration
public QueryContainer Prefix(Field field, string value, double? boost = null, MultiTermQueryRewrite rewrite = null, string name = null)
Parameters
Returns
|
Edit this page
View Source
Prefix(Func<PrefixQueryDescriptor<T>, IPrefixQuery>)
Matches documents that have fields containing terms with a specified prefix (not analyzed).
The prefix query maps to Lucene PrefixQuery.
Declaration
public QueryContainer Prefix(Func<PrefixQueryDescriptor<T>, IPrefixQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Prefix<TValue>(Expression<Func<T, TValue>>, string, double?, MultiTermQueryRewrite, string)
Matches documents that have fields containing terms with a specified prefix (not analyzed).
The prefix query maps to Lucene PrefixQuery.
Declaration
public QueryContainer Prefix<TValue>(Expression<Func<T, TValue>> field, string value, double? boost = null, MultiTermQueryRewrite rewrite = null, string name = null)
Parameters
Returns
Type Parameters
|
Edit this page
View Source
QueryString(Func<QueryStringQueryDescriptor<T>, IQueryStringQuery>)
A query that uses a query parser in order to parse its content.
Declaration
public QueryContainer QueryString(Func<QueryStringQueryDescriptor<T>, IQueryStringQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Range(Func<NumericRangeQueryDescriptor<T>, INumericRangeQuery>)
Matches documents with fields that have terms within a certain numeric range.
Declaration
public QueryContainer Range(Func<NumericRangeQueryDescriptor<T>, INumericRangeQuery> selector)
Parameters
Returns
|
Edit this page
View Source
RankFeature(Func<RankFeatureQueryDescriptor<T>, IRankFeatureQuery>)
A query that only works on rank_feature fields and rank_features fields. Its goal is to boost the score of documents
based on the values of numeric features. It is typically put in a should clause of a bool query so that its score
is added to the score of the query.
Compared to using function_score or other ways to modify the score, this query has the benefit of being able to efficiently
skip non-competitive hits when track_total_hits is not set to true. Speedups may be spectacular.
Declaration
public QueryContainer RankFeature(Func<RankFeatureQueryDescriptor<T>, IRankFeatureQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Raw(string)
A query defined using a raw json string.
The query must be enclosed within '{' and '}'
Declaration
public QueryContainer Raw(string rawJson)
Parameters
Type |
Name |
Description |
string |
rawJson |
The query dsl json
|
Returns
|
Edit this page
View Source
Regexp(Func<RegexpQueryDescriptor<T>, IRegexpQuery>)
Allows you to use regular expression term queries.
"term queries" means that OpenSearch will apply the regexp to the terms produced
by the tokenizer for that field, and not to the original text of the field.
Declaration
public QueryContainer Regexp(Func<RegexpQueryDescriptor<T>, IRegexpQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Script(Func<ScriptQueryDescriptor<T>, IScriptQuery>)
Declaration
public QueryContainer Script(Func<ScriptQueryDescriptor<T>, IScriptQuery> selector)
Parameters
Returns
|
Edit this page
View Source
ScriptScore(Func<ScriptScoreQueryDescriptor<T>, IScriptScoreQuery>)
Declaration
public QueryContainer ScriptScore(Func<ScriptScoreQueryDescriptor<T>, IScriptScoreQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Shape(Func<ShapeQueryDescriptor<T>, IShapeQuery>)
Finds documents with shapes that either intersect, are within, or do not intersect a specified shape.
Declaration
public QueryContainer Shape(Func<ShapeQueryDescriptor<T>, IShapeQuery> selector)
Parameters
Returns
|
Edit this page
View Source
SimpleQueryString(Func<SimpleQueryStringQueryDescriptor<T>, ISimpleQueryStringQuery>)
A query that uses the SimpleQueryParser to parse its context.
Unlike the regular query_string query, the simple_query_string query will
never throw an exception, and discards invalid parts of the query.
Declaration
public QueryContainer SimpleQueryString(Func<SimpleQueryStringQueryDescriptor<T>, ISimpleQueryStringQuery> selector)
Parameters
Returns
|
Edit this page
View Source
SpanContaining(Func<SpanContainingQueryDescriptor<T>, ISpanContainingQuery>)
Returns matches which enclose another span query.
The span containing query maps to Lucene SpanContainingQuery
Declaration
public QueryContainer SpanContaining(Func<SpanContainingQueryDescriptor<T>, ISpanContainingQuery> selector)
Parameters
Returns
|
Edit this page
View Source
SpanFieldMasking(Func<SpanFieldMaskingQueryDescriptor<T>, ISpanFieldMaskingQuery>)
Wraps span queries to allow them to participate in composite single-field Span queries by 'lying' about their search field.
That is, the masked span query will function as normal, but the field points back to the set field of the query.
This can be used to support queries like SpanNearQuery or SpanOrQuery across different fields,
which is not ordinarily permitted.
Declaration
public QueryContainer SpanFieldMasking(Func<SpanFieldMaskingQueryDescriptor<T>, ISpanFieldMaskingQuery> selector)
Parameters
Returns
|
Edit this page
View Source
SpanFirst(Func<SpanFirstQueryDescriptor<T>, ISpanFirstQuery>)
Matches spans near the beginning of a field. The span first query maps to Lucene SpanFirstQuery.
Declaration
public QueryContainer SpanFirst(Func<SpanFirstQueryDescriptor<T>, ISpanFirstQuery> selector)
Parameters
Returns
|
Edit this page
View Source
SpanMultiTerm(Func<SpanMultiTermQueryDescriptor<T>, ISpanMultiTermQuery>)
Wrap a multi term query (one of fuzzy, prefix, term range or regexp query)
as a span query so it can be nested.
Declaration
public QueryContainer SpanMultiTerm(Func<SpanMultiTermQueryDescriptor<T>, ISpanMultiTermQuery> selector)
Parameters
Returns
|
Edit this page
View Source
SpanNear(Func<SpanNearQueryDescriptor<T>, ISpanNearQuery>)
Matches spans which are near one another. One can specify slop, the maximum number of
intervening unmatched positions, as well as whether matches are required to be in-order.
The span near query maps to Lucene SpanNearQuery.
Declaration
public QueryContainer SpanNear(Func<SpanNearQueryDescriptor<T>, ISpanNearQuery> selector)
Parameters
Returns
|
Edit this page
View Source
SpanNot(Func<SpanNotQueryDescriptor<T>, ISpanNotQuery>)
Removes matches which overlap with another span query.
The span not query maps to Lucene SpanNotQuery.
Declaration
public QueryContainer SpanNot(Func<SpanNotQueryDescriptor<T>, ISpanNotQuery> selector)
Parameters
Returns
|
Edit this page
View Source
SpanOr(Func<SpanOrQueryDescriptor<T>, ISpanOrQuery>)
Matches the union of its span clauses.
The span or query maps to Lucene SpanOrQuery.
Declaration
public QueryContainer SpanOr(Func<SpanOrQueryDescriptor<T>, ISpanOrQuery> selector)
Parameters
Returns
|
Edit this page
View Source
SpanTerm(Func<SpanTermQueryDescriptor<T>, ISpanTermQuery>)
Matches spans containing a term. The span term query maps to Lucene SpanTermQuery.
Declaration
public QueryContainer SpanTerm(Func<SpanTermQueryDescriptor<T>, ISpanTermQuery> selector)
Parameters
Returns
|
Edit this page
View Source
SpanWithin(Func<SpanWithinQueryDescriptor<T>, ISpanWithinQuery>)
Returns Matches which are enclosed inside another span query.
The span within query maps to Lucene SpanWithinQuery
Declaration
public QueryContainer SpanWithin(Func<SpanWithinQueryDescriptor<T>, ISpanWithinQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Term(Field, object, double?, string)
Matches documents that have fields that contain a term (not analyzed).
The term query maps to Lucene TermQuery.
Declaration
public QueryContainer Term(Field field, object value, double? boost = null, string name = null)
Parameters
Returns
|
Edit this page
View Source
Term(Func<TermQueryDescriptor<T>, ITermQuery>)
Matches documents that have fields that contain a term (not analyzed).
The term query maps to Lucene TermQuery.
Declaration
public QueryContainer Term(Func<TermQueryDescriptor<T>, ITermQuery> selector)
Parameters
Returns
|
Edit this page
View Source
TermRange(Func<TermRangeQueryDescriptor<T>, ITermRangeQuery>)
Matches documents with fields that have terms within a certain term range.
Declaration
public QueryContainer TermRange(Func<TermRangeQueryDescriptor<T>, ITermRangeQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Term<TValue>(Expression<Func<T, TValue>>, object, double?, string)
Matches documents that have fields that contain a term (not analyzed).
The term query maps to Lucene TermQuery.
Declaration
public QueryContainer Term<TValue>(Expression<Func<T, TValue>> field, object value, double? boost = null, string name = null)
Parameters
Returns
Type Parameters
|
Edit this page
View Source
Terms(Func<TermsQueryDescriptor<T>, ITermsQuery>)
A query that match on any (configurable) of the provided terms.
This is a simpler syntax query for using a bool query with several term queries in the should clauses.
Declaration
public QueryContainer Terms(Func<TermsQueryDescriptor<T>, ITermsQuery> selector)
Parameters
Returns
|
Edit this page
View Source
TermsSet(Func<TermsSetQueryDescriptor<T>, ITermsSetQuery>)
Returns any documents that match with at least one or more of the provided terms.
The terms are not analyzed and thus must match exactly. The number of terms that must match varies
per document and is either controlled by a minimum should match field or
computed per document in a minimum should match script.
Declaration
public QueryContainer TermsSet(Func<TermsSetQueryDescriptor<T>, ITermsSetQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Wildcard(Field, string, double?, MultiTermQueryRewrite, string)
Matches documents that have fields matching a wildcard expression (not analyzed).
Supported wildcards are *, which matches any character sequence (including the empty one), and ?,
which matches any single character. Note this query can be slow, as it needs to iterate over many terms.
In order to prevent extremely slow wildcard queries, a wildcard term should not start with
one of the wildcards * or ?. The wildcard query maps to Lucene WildcardQuery.
Declaration
public QueryContainer Wildcard(Field field, string value, double? boost = null, MultiTermQueryRewrite rewrite = null, string name = null)
Parameters
Returns
|
Edit this page
View Source
Wildcard(Func<WildcardQueryDescriptor<T>, IWildcardQuery>)
Matches documents that have fields matching a wildcard expression (not analyzed).
Supported wildcards are *, which matches any character sequence (including the empty one), and ?,
which matches any single character. Note this query can be slow, as it needs to iterate over many terms.
In order to prevent extremely slow wildcard queries, a wildcard term should not start with
one of the wildcards * or ?. The wildcard query maps to Lucene WildcardQuery.
Declaration
public QueryContainer Wildcard(Func<WildcardQueryDescriptor<T>, IWildcardQuery> selector)
Parameters
Returns
|
Edit this page
View Source
Wildcard<TValue>(Expression<Func<T, TValue>>, string, double?, MultiTermQueryRewrite, string)
Matches documents that have fields matching a wildcard expression (not analyzed).
Supported wildcards are *, which matches any character sequence (including the empty one), and ?,
which matches any single character. Note this query can be slow, as it needs to iterate
over many terms. In order to prevent extremely slow wildcard queries, a wildcard term should
not start with one of the wildcards * or ?. The wildcard query maps to Lucene WildcardQuery.
Declaration
public QueryContainer Wildcard<TValue>(Expression<Func<T, TValue>> field, string value, double? boost = null, MultiTermQueryRewrite rewrite = null, string name = null)
Parameters
Returns
Type Parameters
Implements
Extension Methods