/// <summary>
 /// Describe the query to perform using the static Query class
 /// </summary>
 public virtual RescoreQueryDescriptor <T> Query(QueryContainer query)
 {
     query.ThrowIfNull("query");
     if (query.IsConditionless && !query.IsVerbatim)
     {
         return(this);
     }
     Self.Query = query;
     return(this);
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Filter search
 /// </summary>
 public PercolateDescriptor <TDocument> Filter(QueryContainer filter)
 {
     filter.ThrowIfNull(nameof(filter));
     Self.Filter = filter;
     return(this);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Filter search
 /// </summary>
 public SearchDescriptor <T> PostFilter(QueryContainer filter) => Assign(a => {
     filter.ThrowIfNull(nameof(filter));
     a.PostFilter = filter;
 });